jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/800896 )
Change subject: [bugfix] Fix bugs in nowcommons.py
......................................................................
[bugfix] Fix bugs in nowcommons.py
Bug: T309473
Change-Id: I088d94917539fc1f16a5eb5df7da29282bdfcc51
---
M scripts/nowcommons.py
1 file changed, 4 insertions(+), 4 deletions(-)
Approvals:
DannyS712: Looks good to me, but someone else must approve
Xqt: Looks good to me, approved
jenkins-bot: Verified
diff --git a/scripts/nowcommons.py b/scripts/nowcommons.py
index d323443..43feaec 100755
--- a/scripts/nowcommons.py
+++ b/scripts/nowcommons.py
@@ -277,7 +277,7 @@
+ file_on_commons)
if (local_file_page.title(with_ns=False)
!= commons_file_page.title(with_ns=False)):
- using_pages = list(local_file_page.using_pages())
+ using_pages = list(local_file_page.usingPages())
if using_pages and using_pages != [local_file_page]:
pywikibot.output(
'"<<lightred>>{}<<default>>" is still used in {}
'
@@ -301,10 +301,10 @@
# previous function won't work
is_used = bool(list(pywikibot.FilePage(
self.site,
- page.title()).using_pages(total=1)))
+ page.title()).usingPages(total=1)))
if is_used and self.opt.replaceloose:
bot = ImageBot(
- local_file_page.usimgPages(),
+ local_file_page.usingPages(),
local_file_page.title(with_ns=False,
as_url=True),
commons_file_page.title(with_ns=False),
@@ -313,7 +313,7 @@
bot.run()
# refresh because we want the updated list
using_pages = len(list(pywikibot.FilePage(
- self.site, page.title()).using_pages()))
+ self.site, page.title()).usingPages()))
else:
pywikibot.output('Please change them manually.')
--
To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/800896
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I088d94917539fc1f16a5eb5df7da29282bdfcc51
Gerrit-Change-Number: 800896
Gerrit-PatchSet: 1
Gerrit-Owner: Xqt <info(a)gno.de>
Gerrit-Reviewer: D3r1ck01 <xsavitar.wiki(a)aol.com>
Gerrit-Reviewer: DannyS712 <dannys712.wiki(a)gmail.com>
Gerrit-Reviewer: Rubin <rubin.happy(a)gmail.com>
Gerrit-Reviewer: Xqt <info(a)gno.de>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged