Fix for r85244: HipHop does not support the static form of method_exists().
authorTim Starling <tstarling@users.mediawiki.org>
Mon, 4 Apr 2011 03:42:34 +0000 (03:42 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Mon, 4 Apr 2011 03:42:34 +0000 (03:42 +0000)
includes/Skin.php

index 9efb3f7..7fbce41 100644 (file)
@@ -1554,8 +1554,9 @@ abstract class Skin {
         * @param $args Array Arguments to the method
         */
        function __call( $fname, $args ) {
-               if ( method_exists( 'Linker', $fname ) ) {
-                       return call_user_func_array( array( 'Linker', $fname ), $args );
+               $realFunction = array( 'Linker', $fname );
+               if ( is_callable( $realFunction ) ) {
+                       return call_user_func_array( $realFunction, $args );
                } else {
                        $className = get_class( $this );
                        throw new MWException( "Call to undefined method $className::$fname" );