Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -3536,3 +3536,13 @@ |
3537 | 3537 | return ObjectCache::getInstance( $wgParserCacheType ); |
3538 | 3538 | } |
3539 | 3539 | |
| 3540 | +/** |
| 3541 | + * Call hook functions defined in $wgHooks |
| 3542 | + * |
| 3543 | + * @param $event String: event name |
| 3544 | + * @param $args Array: parameters passed to hook functions |
| 3545 | + * @return Boolean |
| 3546 | + */ |
| 3547 | +function wfRunHooks( $event, $args = array() ) { |
| 3548 | + return Hooks::run( $event, $args ); |
| 3549 | +} |
Index: trunk/phase3/includes/Setup.php |
— | — | @@ -334,7 +334,6 @@ |
335 | 335 | wfProfileIn( $fname . '-includes' ); |
336 | 336 | require_once( "$IP/includes/normal/UtfNormalUtil.php" ); |
337 | 337 | require_once( "$IP/includes/GlobalFunctions.php" ); |
338 | | - require_once( "$IP/includes/Hooks.php" ); |
339 | 338 | require_once( "$IP/includes/ProxyTools.php" ); |
340 | 339 | require_once( "$IP/includes/ImageFunctions.php" ); |
341 | 340 | require_once( "$IP/includes/normal/UtfNormalDefines.php" ); |
Index: trunk/phase3/includes/Hooks.php |
— | — | @@ -23,25 +23,6 @@ |
24 | 24 | * @file |
25 | 25 | */ |
26 | 26 | |
27 | | -/** |
28 | | - * Call hook functions defined in $wgHooks |
29 | | - * |
30 | | - * Because programmers assign to $wgHooks, we need to be very |
31 | | - * careful about its contents. So, there's a lot more error-checking |
32 | | - * in here than would normally be necessary. |
33 | | - * |
34 | | - * @param $event String: event name |
35 | | - * @param $args Array: parameters passed to hook functions |
36 | | - * @return Boolean |
37 | | - */ |
38 | | -function wfRunHooks( $event, $args = array() ) { |
39 | | - return Hooks::run( $event, $args ); |
40 | | -} |
41 | | - |
42 | | -function hookErrorHandler( $errno, $errstr ) { |
43 | | - return Hooks::hookErrorHandler( $errno, $errstr ); |
44 | | -} |
45 | | - |
46 | 27 | class MWHookException extends MWException {} |
47 | 28 | |
48 | 29 | /** |