Page MenuHomePhabricator

TitlesMultiselectWidget::$showMissing is confusingly named
Open, Needs TriagePublic

Description

TitlesMultiselectWidget::$showMissing is documented as "Show missing pages" so you'd expect it to enable/disable displaying non-existent pages in the page list of the widget. What it actually does is enable/disable showing the exact title you have typed in in the typeahead dropdown, so basically it controls whether it is possible to add non-existing pages. (The configuration setting is eventually passed to TitleWidget, where the naming makes sense, but here it doesn't.)

It would be nice to rename it to something more intuitive, like canAddMissing.

Event Timeline

Tgr created this task.Jun 3 2020, 2:21 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJun 3 2020, 2:21 PM
Tgr updated the task description. (Show Details)Jun 3 2020, 2:23 PM

Change 602090 had a related patch set uploaded (by Gergő Tisza; owner: Gergő Tisza):
[mediawiki/core@master] Clarify documentation of TitlesMultiselectWidget::$showMissing

https://gerrit.wikimedia.org/r/602090

Change 602090 merged by jenkins-bot:
[mediawiki/core@master] Clarify documentation of TitlesMultiselectWidget::$showMissing

https://gerrit.wikimedia.org/r/602090