Xqt has submitted this change. ( 
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1186432?usp=email )

Change subject: [IMPR] use Site.has_group() to determine the botflag
......................................................................

[IMPR] use Site.has_group() to determine the botflag

Change-Id: I51e5c8c00d3f20e985de12dbd7afa77e1ab25eff
---
M scripts/create_isbn_edition.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Xqt: Verified; Looks good to me, approved




diff --git a/scripts/create_isbn_edition.py b/scripts/create_isbn_edition.py
index 07d7d28..e788265 100755
--- a/scripts/create_isbn_edition.py
+++ b/scripts/create_isbn_edition.py
@@ -1561,7 +1561,7 @@
                    f'{pywikibot.__version__}, {pgmlic}, {creator}')

     # This script requires a bot flag
-    wdbotflag = 'bot' in pywikibot.User(repo, repo.user()).groups()
+    wdbotflag = repo.has_group('bot')

     # Prebuilt targets
     target_author = pywikibot.ItemPage(repo, AUTHORINSTANCE)

--
To view, visit 
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1186432?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.wikimedia.org/r/settings?usp=email

Gerrit-MessageType: merged
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I51e5c8c00d3f20e985de12dbd7afa77e1ab25eff
Gerrit-Change-Number: 1186432
Gerrit-PatchSet: 1
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to