]> gitweb.pimeys.fr Git - bots/basile.git/commitdiff
Erreur de sémantique dans le drop()
authorVincent Le Gallic <legallic@crans.org>
Fri, 4 Sep 2015 09:44:03 +0000 (11:44 +0200)
committerVincent Le Gallic <legallic@crans.org>
Fri, 4 Sep 2015 09:44:03 +0000 (11:44 +0200)
basile.py

index 86e8105df718f5ea96838885e468430959d060ef..81ada60551be2baa24c09ceceb6ddcbad9bb5a52 100755 (executable)
--- a/basile.py
+++ b/basile.py
@@ -333,10 +333,11 @@ class Basile(ircbot.SingleServerIRCBot):
         elif cmd == u"drop":
             if len(message) > 1:
                 if self.users.has(auteur):
+                    idbde = self.users[auteur].idbde
                     password = " ".join(message[1:])
-                    success, _, _ = self.new_connection_NK(serv, "#%s" % self.users[auteur].idbde, password)
+                    success, _, _ = self.new_connection_NK(serv, "#%s" % idbde, password)
                     if success:
-                        self.users.drop(auteur)
+                        self.users.drop(idbde)
                         log(self.serveur, "priv", auteur, " ".join(message) + "[successful]")
                         serv.privmsg(auteur, "Pseudo oublié.")
                     else: