jenkins-bot has submitted this change and it was merged.
Change subject: backport Ic8ef2868ef9c55a1cec57a17f5601652918a62c7 from core ......................................................................
backport Ic8ef2868ef9c55a1cec57a17f5601652918a62c7 from core
bug: 55161 Change-Id: Ib5def7736b3ed7f682e880438ab21d5f5253ce6e --- M cosmetic_changes.py 1 file changed, 3 insertions(+), 4 deletions(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/cosmetic_changes.py b/cosmetic_changes.py index 528104c..b15c226 100644 --- a/cosmetic_changes.py +++ b/cosmetic_changes.py @@ -578,10 +578,9 @@ German, and French Wikipedia. It might be that it is not wanted on other wikis. If there are any complaints, please file a bug report. """ - exceptions = ['comment', 'math', 'nowiki', 'pre', 'source', 'template', - 'timeline'] - if not (self.redirect or self.template) and \ - pywikibot.calledModuleName() != 'capitalize_redirects': + if not self.template: + exceptions = ['comment', 'math', 'nowiki', 'pre', 'source', 'template', + 'timeline', self.site.redirectRegex()] text = pywikibot.replaceExcept( text, r'(?m)^(?P<bullet>[:;]*(*+|#+)[:;*#]*)(?P<char>[^\s*#:;].+?)',