X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiFeedRecentChanges.php;h=e5dba8fe4a9a68596c14939a60e44a34e8a3dac9;hb=1e4bf35253a6f672c57c1430c895049591fb090b;hp=0b04c8cc928e2d88a17e6804877130b3845a46d8;hpb=dae4c94d893057345f62a3d498fb85c0a54de5a6;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiFeedRecentChanges.php b/includes/api/ApiFeedRecentChanges.php index 0b04c8cc92..e5dba8fe4a 100644 --- a/includes/api/ApiFeedRecentChanges.php +++ b/includes/api/ApiFeedRecentChanges.php @@ -63,8 +63,8 @@ class ApiFeedRecentChanges extends ApiBase { $feedFormat = $this->params['feedformat']; $specialClass = $this->params['target'] !== null - ? 'SpecialRecentchangeslinked' - : 'SpecialRecentchanges'; + ? SpecialRecentChangesLinked::class + : SpecialRecentChanges::class; $formatter = $this->getFeedObject( $feedFormat, $specialClass ); @@ -90,12 +90,12 @@ class ApiFeedRecentChanges extends ApiBase { * Return a ChannelFeed object. * * @param string $feedFormat Feed's format (either 'rss' or 'atom') - * @param string $specialClass Relevant special page name (either 'SpecialRecentchanges' or - * 'SpecialRecentchangeslinked') + * @param string $specialClass Relevant special page name (either 'SpecialRecentChanges' or + * 'SpecialRecentChangesLinked') * @return ChannelFeed */ public function getFeedObject( $feedFormat, $specialClass ) { - if ( $specialClass === 'SpecialRecentchangeslinked' ) { + if ( $specialClass === SpecialRecentChangesLinked::class ) { $title = Title::newFromText( $this->params['target'] ); if ( !$title ) { $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $this->params['target'] ) ] ); @@ -169,16 +169,6 @@ class ApiFeedRecentChanges extends ApiBase { 'showlinkedto' => false, ]; - if ( $config->get( 'AllowCategorizedRecentChanges' ) ) { - $ret += [ - 'categories' => [ - ApiBase::PARAM_TYPE => 'string', - ApiBase::PARAM_ISMULTI => true, - ], - 'categories_any' => false, - ]; - } - return $ret; }