[go: up one dir, main page]

Page MenuHomePhabricator

Unify ParserOutput::{get,set}{TitleText,DisplayTitle}
Open, LowPublic

Description

We seem to have two very similar sets of methods in ParserOutput: setDisplayTitle() turns around and calls setTitleText directly, then sets an additional page property, while getDisplayTitle calls getTitleText() and just remaps the empty string to boolean false when returning it.

It seems like we ought to be able to deprecate and remove one of these -- probably {get,set}TitleText().

Related Objects

Event Timeline

There are subtle differences between the two -- language converter for example uses setTitleText() to handle the -{T}- markup, not setDisplayTitle.
See also:

Like TOCData, I think the design intent is that exactly one fragment contains a non-empty TitleText, and that is that one that should be used.

Change 908936 had a related patch set uploaded (by C. Scott Ananian; author: Subramanya Sastry):

[mediawiki/core@master] ParserOutput: Ensure page title is updated after merging properties

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

Change 908936 merged by jenkins-bot:

[mediawiki/core@master] ParserOutput: Ensure page title is updated after merging properties

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

Change 946988 had a related patch set uploaded (by C. Scott Ananian; author: C. Scott Ananian):

[mediawiki/core@master] Store DISPLAYTITLE components in split form

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