X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fpage%2FWikiPage.php;h=d30f589e74dae9f71da9e75af6a669e0789e6978;hb=eca35903a2390bf7eb503fa0ede6a76ce556dc55;hp=2f900f971f334abca53f0e140984298a0b442102;hpb=25bdfe5dc8d2a106278b65e8e5785f51b7034317;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/page/WikiPage.php b/includes/page/WikiPage.php index 2f900f971f..d30f589e74 100644 --- a/includes/page/WikiPage.php +++ b/includes/page/WikiPage.php @@ -2154,10 +2154,12 @@ class WikiPage implements Page, IDBAccessObject { * - changed: boolean, whether the revision changed the content (default true) * - created: boolean, whether the revision created the page (default false) * - moved: boolean, whether the page was moved (default false) - * - oldcountable: boolean or null (default null): + * - oldcountable: boolean, null, or string 'no-change' (default null): * - boolean: whether the page was counted as an article before that * revision, only used in changed is true and created is false - * - null: don't change the article count + * - null: if created is false, don't update the article count; if created + * is true, do update the article count + * - 'no-change': don't update the article count, ever */ public function doEditUpdates( Revision $revision, User $user, array $options = array() ) { global $wgEnableParserCache; @@ -2212,7 +2214,9 @@ class WikiPage implements Page, IDBAccessObject { $title = $this->mTitle->getPrefixedDBkey(); $shortTitle = $this->mTitle->getDBkey(); - if ( !$options['changed'] && !$options['moved'] ) { + if ( $options['oldcountable'] === 'no-change' || + ( !$options['changed'] && !$options['moved'] ) + ) { $good = 0; } elseif ( $options['created'] ) { $good = (int)$this->isCountable( $editInfo );