Xqt added a comment.

One idea to solve it is replacing

# we want to throw away the original link text
replaceit = link_text == page_title

with

# we want to throw away the original link text
bracketless_link = pywikibot.Page(current_page.site,
                                  link_text)
replaceit = bracketless_link.title(
    without_brackets=True) == page_title

to remove the bracket extenson of the title.

Another way would be a force option to take the new link for the visual content.


TASK DETAIL
https://phabricator.wikimedia.org/T216592

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Xqt
Cc: Aklapper, jhsoby-WMNO, pywikibot-bugs-list, Dvorapa, Xqt, Wenyi, Mahveotm, Tbscho, MayS, Mdupont, JJMC89, Avicennasis, mys_721tx, jayvdb, Dalba, Masti, Alchimista, Rxy
_______________________________________________
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs

Reply via email to