diff options
Diffstat (limited to 'includes/Hooks.php')
-rw-r--r-- | includes/Hooks.php | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/includes/Hooks.php b/includes/Hooks.php index dd08d03b..e1c1d50b 100644 --- a/includes/Hooks.php +++ b/includes/Hooks.php @@ -86,7 +86,7 @@ class Hooks { * * @param $event String: event name * @param $args Array: parameters passed to hook functions - * @return Boolean + * @return Boolean True if no handler aborted the hook */ public static function run( $event, $args = array() ) { global $wgHooks; @@ -222,9 +222,7 @@ class Hooks { /* String return is an error; false return means stop processing. */ if ( is_string( $retval ) ) { - global $wgOut; - $wgOut->showFatalError( $retval ); - return false; + throw new FatalError( $retval ); } elseif( $retval === null ) { if ( $closure ) { $prettyFunc = "$event closure"; |