Remove call to deprecated MWInit::methodExists with method_exists

MWInit::methodExists was deprecated in 1.22.

Change-Id: I5bbda455c64afa8ac0c9f7d1af03c4c57cff06ca
This commit is contained in:
Kunal Mehta 2013-07-27 14:12:24 -07:00 committed by Legoktm
parent 0052446e2b
commit 5596a3b572

View file

@ -264,9 +264,7 @@ class AbuseFilterHooks {
* @return bool
*/
protected static function identicalPageObjects( $page1, $page2 ) {
if ( ( class_exists('MWInit') && MWInit::methodExists( 'Article', 'getPage' ) ) ||
( !class_exists('MWInit') && method_exists('Article', 'getPage') )
) {
if ( method_exists('Article', 'getPage') ) {
$wpage1 = ( $page1 instanceof Article ) ? $page1->getPage() : $page1;
$wpage2 = ( $page2 instanceof Article ) ? $page2->getPage() : $page2;
return ( $wpage1 === $wpage2 );