Dvorapa has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/395008 )
Change subject: [bugfix] Don't add blank line between categories and defaultsort
......................................................................
[bugfix] Don't add blank line between categories and defaultsort
Bug: T155233
Change-Id: I03e885b912a5f8c165a421ee46ca06e41c10b1eb
---
M pywikibot/textlib.py
1 file changed, 4 insertions(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core
refs/changes/08/395008/1
diff --git a/pywikibot/textlib.py b/pywikibot/textlib.py
index ebb72a9..78f0deb 100644
--- a/pywikibot/textlib.py
+++ b/pywikibot/textlib.py
@@ -1232,7 +1232,10 @@
'German\nWikipedia on pages that contain the Personendaten '
'template because of the\nnon-standard placement of that
template.\n'
'See
https://de.wikipedia.org/wiki/Hilfe:Personendaten#Kopiervorlage')
- separator = site.family.category_text_separator
+ if re.search(r'\{\{(' + r'|'.join(site.getmagicwords('defaultsort')) +
')', new, flags=re.I):
+ separator = config.line_separator
+ else:
+ separator = site.family.category_text_separator
iseparator = site.family.interwiki_text_separator
separatorstripped = separator.strip()
iseparatorstripped = iseparator.strip()
--
To view, visit https://gerrit.wikimedia.org/r/395008
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I03e885b912a5f8c165a421ee46ca06e41c10b1eb
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Dvorapa <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits