HomePhabricator

Rewrote the article counting code and related:

Description

Rewrote the article counting code and related:

  • (bug 26033, bug 24754) Added $wgArticleCountMethod to have a more flexible way to define which method to use to define if a page is an article or not and deprecated $wgUseCommaCount. There is now a new 'any' method to count any article that is in a content namespace and not a redirect.
  • (bug 11868) If using links to count articles, Article::isCountable() will now use the ParserOutput to check if there's a link instead of checking for the "[[" string. Changed Article::isCountable() to take a stdObject or false for the first parameters. If false is passed, the result will be based on the current article's state (i.e. database). The only call outside of the Article class is in DeleteAction (including extensions).
  • Removed this horror of Article::$mGoodAdjustment and Article::$mTotalAdjustment, replaced by the new $created parameter on Article::editUpdates(); simplified Article::createUpdates()
  • Updated Import.php to take advantage of the new parameter and make a single call to Article::editUpdates()

Details

Committed
IAlexMay 14 2011, 5:11 PM
Parents
rSVN88112: follow up to r88108
Branches
Unknown
Tags
Unknown
ChangeId
None