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

Change subject: [bugfix] Create APISite object through pywikibot.Site wrapper
......................................................................

[bugfix] Create APISite object through pywikibot.Site wrapper

Site function caches created sites in global _sites

Bug: T226157
Change-Id: Ie4e529aedd830dea894e08f0f9e50f6bc1080183
---
M pywikibot/site.py
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/pywikibot/site.py b/pywikibot/site.py
index bef3935..24049dc 100644
--- a/pywikibot/site.py
+++ b/pywikibot/site.py
@@ -1885,7 +1885,7 @@
                     if site['dbname'] == dbname:
                         if site['code'] == 'wiki':
                             site['code'] = 'wikipedia'
-                        return cls(lang, site['code'])
+                        return pywikibot.Site(lang, site['code'])
             else:  # key == 'specials'
                 for site in val:
                     if site['dbname'] == dbname:

--
To view, visit https://gerrit.wikimedia.org/r/518025
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.wikimedia.org/r/settings

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ie4e529aedd830dea894e08f0f9e50f6bc1080183
Gerrit-Change-Number: 518025
Gerrit-PatchSet: 3
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: John Vandenberg <[email protected]>
Gerrit-Reviewer: Matěj Suchánek <[email protected]>
Gerrit-Reviewer: Zhuyifei1999 <[email protected]>
Gerrit-Reviewer: jenkins-bot (75)
_______________________________________________
Pywikibot-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-commits

Reply via email to