jenkins-bot has submitted this change and it was merged.
Change subject: i18n: allow empty translations
......................................................................
i18n: allow empty translations
Also do this for non-TWN translations
Followup-for-Change-Id: Icf8ca6a76d1fdcbe7be3a4ac276a5e9d0688108b
Change-Id: I662136f8cc9e992fc63dfee0a35b861fe4785627
---
M pywikibot/i18n.py
1 file changed, 1 insertion(+), 1 deletion(-)
Approvals:
Ladsgroup: Looks good to me, approved
jenkins-bot: Verified
diff --git a/pywikibot/i18n.py b/pywikibot/i18n.py
index ac2c0f6..bb2b26d 100644
--- a/pywikibot/i18n.py
+++ b/pywikibot/i18n.py
@@ -285,7 +285,7 @@
else:
trans = list(xdict.values())[0]
code = list(xdict.keys())[0]
- if not trans:
+ if trans is None:
return # return None if we have no translation found
if parameters is None:
return trans
--
To view, visit
https://gerrit.wikimedia.org/r/103540
To unsubscribe, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I662136f8cc9e992fc63dfee0a35b861fe4785627
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Merlijn van Deen <valhallasw(a)arctus.nl>
Gerrit-Reviewer: Ladsgroup <ladsgroup(a)gmail.com>
Gerrit-Reviewer: jenkins-bot