home · contact · privacy
Fix typo in variable name.
authorChristian Heller <c.heller@plomlompom.de>
Fri, 5 Feb 2016 10:19:23 +0000 (11:19 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Fri, 5 Feb 2016 10:19:23 +0000 (11:19 +0100)
plomlombot.py

index 786b072bf483d1c69cfd19e18c18895214bbbf6b..b95bb42499f2f99f3c701b869d4ac84670efcc8b 100755 (executable)
@@ -226,7 +226,7 @@ def handle_command(command, argument, notice, target, session):
         msg = ""
         while 1:
             new_end = markov(snippet)
         msg = ""
         while 1:
             new_end = markov(snippet)
-            for name in session.uses_in_chan:
+            for name in session.users_in_chan:
                 if new_end[:len(name)] == name.lower():
                     new_end = "malkovich" + new_end[len(name):]
                     break
                 if new_end[:len(name)] == name.lower():
                     new_end = "malkovich" + new_end[len(name):]
                     break
@@ -314,7 +314,7 @@ class Session:
         self.io = io
         self.nickname = nickname
         self.channel = channel
         self.io = io
         self.nickname = nickname
         self.channel = channel
-        self.uses_in_chan = []
+        self.users_in_chan = []
         self.twtfile = twtfile
         self.io.send_line("NICK " + self.nickname)
         self.io.send_line("USER " + username + " 0 * : ")
         self.twtfile = twtfile
         self.io.send_line("NICK " + self.nickname)
         self.io.send_line("USER " + username + " 0 * : ")
@@ -382,14 +382,14 @@ class Session:
                 elif tokens[1] == "353":
                     names = tokens[5:]
                     names[0] = names[0][1:]
                 elif tokens[1] == "353":
                     names = tokens[5:]
                     names[0] = names[0][1:]
-                    self.uses_in_chan += names
+                    self.users_in_chan += names
                 elif tokens[1] == "JOIN":
                     name = name_from_join_or_part(tokens)
                     if name != self.nickname:
                 elif tokens[1] == "JOIN":
                     name = name_from_join_or_part(tokens)
                     if name != self.nickname:
-                        self.uses_in_chan += [name]
+                        self.users_in_chan += [name]
                 elif tokens[1] == "PART":
                     name = name_from_join_or_part(tokens)
                 elif tokens[1] == "PART":
                     name = name_from_join_or_part(tokens)
-                    del(self.uses_in_chan[self.uses_in_chan.index(name)])
+                    del(self.users_in_chan[self.users_in_chan.index(name)])
 
 def parse_command_line_arguments():
     parser = argparse.ArgumentParser()
 
 def parse_command_line_arguments():
     parser = argparse.ArgumentParser()