jenkins-bot has submitted this change. ( 
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/640929 )

Change subject: [bugfix] Do not strip all whitespaces from title
......................................................................

[bugfix] Do not strip all whitespaces from title

Bug: T197642
Change-Id: Ia482218cc569e566dbd8bfd0927a469667e0a26c
---
M pywikibot/page/__init__.py
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/pywikibot/page/__init__.py b/pywikibot/page/__init__.py
index fdc1973..4142102 100644
--- a/pywikibot/page/__init__.py
+++ b/pywikibot/page/__init__.py
@@ -5988,9 +5988,9 @@

         # "empty" local links can only be self-links
         # with a fragment identifier.
-        if not t.strip() and not self._is_interwiki:
-            raise pywikibot.InvalidTitle('The link does not contain a page '
-                                         'title')
+        if not t.strip(' ') and not self._is_interwiki:  # T197642
+            raise pywikibot.InvalidTitle(
+                'The link does not contain a page title')

         if self._site.namespaces[self._namespace].case == 'first-letter':
             t = first_upper(t)

--
To view, visit https://gerrit.wikimedia.org/r/c/pywikibot/core/+/640929
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: Ia482218cc569e566dbd8bfd0927a469667e0a26c
Gerrit-Change-Number: 640929
Gerrit-PatchSet: 3
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: Dvorapa <[email protected]>
Gerrit-Reviewer: JJMC89 <[email protected]>
Gerrit-Reviewer: Zhuyifei1999 <[email protected]>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged
_______________________________________________
Pywikibot-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-commits

Reply via email to