jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/370177 )

Change subject: [cleanup] code cleanup
......................................................................


[cleanup] code cleanup

- WelcomeBot._checkQueue is never used and can be removed
- set self.welcomed_users only once when needed

Change-Id: Icc2c90b23bf813e757d3f77fe0f6867c9850d4cb
---
M scripts/welcome.py
1 file changed, 1 insertion(+), 5 deletions(-)

Approvals:
  Mpaa: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/scripts/welcome.py b/scripts/welcome.py
index 6496438..c974023 100755
--- a/scripts/welcome.py
+++ b/scripts/welcome.py
@@ -431,8 +431,6 @@
 
         if globalvar.randomSign:
             self.defineSign(True)
-        if __name__ != '__main__':  # use only in module call
-            self._checkQueue = []
 
     def check_managed_sites(self):
         """Check that site is managed by welcome.py."""
@@ -812,9 +810,7 @@
                     pywikibot.output(
                         u'Putting the log of the latest %d users...'
                         % welcomed_count)
-                if self.makelogpage(self.welcomed_users):
-                    self.welcomed_users = []
-                else:
+                if not self.makelogpage(self.welcomed_users):
                     continue
                 self.welcomed_users = []
             if hasattr(self, '_BAQueue'):

-- 
To view, visit https://gerrit.wikimedia.org/r/370177
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Icc2c90b23bf813e757d3f77fe0f6867c9850d4cb
Gerrit-PatchSet: 2
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Xqt <i...@gno.de>
Gerrit-Reviewer: Magul <tomasz.magul...@gmail.com>
Gerrit-Reviewer: Mpaa <mpaa.w...@gmail.com>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
Pywikibot-commits mailing list
Pywikibot-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-commits

Reply via email to