From 2f605185fd91a2b770eef71fe6ae4c9a1aad0b0f Mon Sep 17 00:00:00 2001 From: Kunal Mehta Date: Wed, 24 Jul 2013 00:59:13 -0700 Subject: [PATCH] Use PHP's built-in class_exists instead of MWInit::classExists MWInit::classExists is deprecated as of 1.22 in favor of the class_exists PHP built-in. Change-Id: Ia51ac62c10c8191f00232f709d4d4df295583354 --- MathCaptcha.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MathCaptcha.class.php b/MathCaptcha.class.php index fdb6d1ff1..ac220baa8 100644 --- a/MathCaptcha.class.php +++ b/MathCaptcha.class.php @@ -39,7 +39,7 @@ class MathCaptcha extends SimpleCaptcha { /** Fetch the math */ function fetchMath( $sum ) { - if ( MWInit::classExists( 'MathRenderer' ) ) { + if ( class_exists( 'MathRenderer' ) ) { $math = MathRenderer::getRenderer( $sum, array(), MW_MATH_PNG ); } else { throw new MWException( 'MathCaptcha requires the Math extension for MediaWiki versions 1.18 and above.' );