Pārlūkot izejas kodu

Don't automorph if bot is pinged

denikson 6 gadi atpakaļ
vecāks
revīzija
2450670070
1 mainītis faili ar 3 papildinājumiem un 0 dzēšanām
  1. 3 0
      commands/facemorph.js

+ 3 - 0
commands/facemorph.js

@@ -124,6 +124,9 @@ const onMessage = (msg, contents, actionsDone) => {
     if (actionsDone)
         return false;
 
+    if(msg.mentions.users.size > 0 && msg.mentions.users.first().id == client.user.id)
+        return false;
+
     let imageAttachment = msg.attachments.find(v => util.isValidImage(v.filename));
 
     if (imageAttachment) {