Xqt has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1050776?usp=email )
Change subject: [flake8] Fix flake C420 issue ......................................................................
[flake8] Fix flake C420 issue
Bug: T368848 Change-Id: I9eeed2e6d856e162aecd26d100a61b1e89da307c --- M pywikibot/family.py 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: jenkins-bot: Verified Xqt: Verified; Looks good to me, approved
diff --git a/pywikibot/family.py b/pywikibot/family.py index 22961fd..e8e8242 100644 --- a/pywikibot/family.py +++ b/pywikibot/family.py @@ -738,7 +738,7 @@
:return: mapping of old codes to new codes (or None) """ - data = {code: None for code in self.interwiki_removals} + data = dict.fromkeys(self.interwiki_removals) data.update(self.interwiki_replacements) return types.MappingProxyType(data)