diff sat/core/sat_main.py @ 2765:378188abe941

misc: replaced all "dummy" by the more conventional and readable "__" ("_" being used for gettext)
author Goffi <goffi@goffi.org>
date Fri, 11 Jan 2019 11:13:15 +0100
parents e347e32aa07f
children a97c43dc4924
line wrap: on
line diff
--- a/sat/core/sat_main.py	Fri Jan 11 10:18:02 2019 +0100
+++ b/sat/core/sat_main.py	Fri Jan 11 11:13:15 2019 +0100
@@ -411,7 +411,7 @@
         if options is None:
             options = {}
 
-        def connectProfile(dummy=None):
+        def connectProfile(__=None):
             if self.isConnected(profile):
                 log.info(_("already connected !"))
                 return True
@@ -420,7 +420,7 @@
                 d = xmpp.SatXMPPComponent.startConnection(self, profile, max_retries)
             else:
                 d = xmpp.SatXMPPClient.startConnection(self, profile, max_retries)
-            return d.addCallback(lambda dummy: False)
+            return d.addCallback(lambda __: False)
 
         d = self.memory.startSession(password, profile)
         d.addCallback(connectProfile)
@@ -492,7 +492,7 @@
     def getContacts(self, profile_key):
         client = self.getClient(profile_key)
 
-        def got_roster(dummy):
+        def got_roster(__):
             ret = []
             for item in client.roster.getItems():  # we get all items for client's roster
                 # and convert them to expected format
@@ -1032,7 +1032,7 @@
             progress_all[profile] = progress_dict
             for (
                 progress_id,
-                (dummy, progress_metadata),
+                (__, progress_metadata),
             ) in client._progress_cb.iteritems():
                 progress_dict[progress_id] = progress_metadata
         return progress_all
@@ -1052,7 +1052,7 @@
             profile = client.profile
             progress_dict = {}
             progress_all[profile] = progress_dict
-            for progress_id, (progress_cb, dummy) in client._progress_cb.iteritems():
+            for progress_id, (progress_cb, __) in client._progress_cb.iteritems():
                 progress_dict[progress_id] = progress_cb(progress_id, profile)
         return progress_all