Bläddra i källkod

Adding curse no list

Kirk Trombley 6 år sedan
förälder
incheckning
24c977de84
1 ändrade filer med 3 tillägg och 1 borttagningar
  1. 3 1
      src/plugins/curse.py

+ 3 - 1
src/plugins/curse.py

@@ -111,7 +111,9 @@ def curse(db, msg):
     if not name.startswith("!"):
         person_id = name.strip().lower()
         if is_banned(msg, person_id):
-            return RollbotResponse(msg, txt="Hey! You aren't allowed to affect that person's score!")
+            if msg.sender_id in get_secret("curse.nolist"):
+                return "No!!!!!!!!!!"
+            return "Hey! You aren't allowed to affect that person's score!"
         score = get_score(db, msg.group_id, person_id)
         # Note we do this instead of += b/c that can create race conditions in sqlalchemy
         score.curses = score.curses + 1