module.exports.config = { name: "eval", version: "1.0.0", hasPermssion: 2, description: "Evaluate JavaScript code", usePrefix: true, credits: "Jonell Magallanes", cooldowns: 3, commandCategory: "Utility", }; module.exports.run = async function ({ api, event, args }) { const { threadID, messageID } = event; const code = args.join(" "); if (!code) { return api.sendMessage("Please provide JavaScript code to evaluate.", threadID, messageID); } try { let result = await eval(code); if (typeof result !== 'string') { result = require('util').inspect(result, { depth: 0 }); } api.sendMessage(`āœļø š—˜š˜ƒš—®š—¹š˜‚š—®š˜š—¶š—¼š—» š—„š—²š˜€š˜‚š—¹š˜\n━━━━━━━━━━━━━━━━━━\n${result}`, threadID, messageID); } catch (error) { api.sendMessage(`šŸ”“ š—˜š˜ƒš—®š—¹š˜‚š—®š˜š—¶š—¼š—» š—˜š—æš—æš—¼š—æ\n━━━━━━━━━━━━━━━━━━\n${error.message}`, threadID, messageID); } };