From 776b4aa829e333e5eba591f4751ce6c80b2259a0 Mon Sep 17 00:00:00 2001 From: Andrew Garrett Date: Mon, 27 Jul 2009 10:45:18 +0000 Subject: [PATCH] Fix for bug 19887, make sure tagfilter form option is "consumed" (whatever that means), prevents old value from being propagated through the form. --- includes/specials/SpecialNewpages.php | 3 ++- includes/specials/SpecialRecentchanges.php | 2 +- includes/specials/SpecialRecentchangeslinked.php | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/includes/specials/SpecialNewpages.php b/includes/specials/SpecialNewpages.php index 20cb120f00..860785724f 100644 --- a/includes/specials/SpecialNewpages.php +++ b/includes/specials/SpecialNewpages.php @@ -165,6 +165,7 @@ class SpecialNewpages extends SpecialPage { $this->opts->consumeValue( 'offset' ); // don't carry offset, DWIW $namespace = $this->opts->consumeValue( 'namespace' ); $username = $this->opts->consumeValue( 'username' ); + $tagFilterVal = $this->opts->consumeValue( 'tagfilter' ); // Check username input validity $ut = Title::makeTitleSafe( NS_USER, $username ); @@ -177,7 +178,7 @@ class SpecialNewpages extends SpecialPage { } $hidden = implode( "\n", $hidden ); - $tagFilter = ChangeTags::buildTagFilterSelector( $this->opts['tagfilter'] ); + $tagFilter = ChangeTags::buildTagFilterSelector( $tagFilterVal ); if ($tagFilter) list( $tagFilterLabel, $tagFilterSelector ) = $tagFilter; diff --git a/includes/specials/SpecialRecentchanges.php b/includes/specials/SpecialRecentchanges.php index ab3830b70c..caeda530e6 100644 --- a/includes/specials/SpecialRecentchanges.php +++ b/includes/specials/SpecialRecentchanges.php @@ -414,7 +414,7 @@ class SpecialRecentChanges extends SpecialPage { $defaults = $opts->getAllValues(); $nondefaults = $opts->getChangedValues(); - $opts->consumeValues( array( 'namespace', 'invert' ) ); + $opts->consumeValues( array( 'namespace', 'invert', 'tagfilter' ) ); $panel = array(); $panel[] = $this->optionsPanel( $defaults, $nondefaults ); diff --git a/includes/specials/SpecialRecentchangeslinked.php b/includes/specials/SpecialRecentchangeslinked.php index 0a680f3a88..3905b43864 100644 --- a/includes/specials/SpecialRecentchangeslinked.php +++ b/includes/specials/SpecialRecentchangeslinked.php @@ -168,7 +168,7 @@ class SpecialRecentchangeslinked extends SpecialRecentchanges { } function getExtraOptions( $opts ){ - $opts->consumeValues( array( 'showlinkedto', 'target' ) ); + $opts->consumeValues( array( 'showlinkedto', 'target', 'tagfilter' ) ); $extraOpts = array(); $extraOpts['namespace'] = $this->namespaceFilterForm( $opts ); $extraOpts['target'] = array( wfMsgHtml( 'recentchangeslinked-page' ), -- 2.20.1