Fix eval
This commit is contained in:
parent
62b9683f8f
commit
945e4f439f
1 changed files with 1 additions and 1 deletions
2
index.js
2
index.js
|
@ -138,7 +138,7 @@ client.on("messageCreate", (msg) => {
|
||||||
if(!msg.content.startsWith("rps!ev")) return;
|
if(!msg.content.startsWith("rps!ev")) return;
|
||||||
if(!allowed.includes(msg.author.id)) return msg.channel.send("Nu perms!");
|
if(!allowed.includes(msg.author.id)) return msg.channel.send("Nu perms!");
|
||||||
try{
|
try{
|
||||||
msg.channel.send(msg.content.replace("rps!ev")).catch(e => {msg.channel.send(e.stack)});
|
msg.channel.send(new String(eval(msg.content.replace("rps!ev", ""))).valueOf()).catch(e => {msg.channel.send(e.stack)});
|
||||||
} catch(e){
|
} catch(e){
|
||||||
msg.channel.send(e.stack).catch(e => {msg.channel.send("Well thats ironic, an error for an error message: \n" + e.stack)});
|
msg.channel.send(e.stack).catch(e => {msg.channel.send("Well thats ironic, an error for an error message: \n" + e.stack)});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue