Merge "Drop wfRunHooks, deprecated since 1.25"
[lhc/web/wiklou.git] / includes / GlobalFunctions.php
index 868fda3..b536e69 100644 (file)
@@ -2455,33 +2455,6 @@ function wfDiff( $before, $after, $params = '-u' ) {
        return $diff;
 }
 
-/**
- * This function works like "use VERSION" in Perl, the program will die with a
- * backtrace if the current version of PHP is less than the version provided
- *
- * This is useful for extensions which due to their nature are not kept in sync
- * with releases, and might depend on other versions of PHP than the main code
- *
- * Note: PHP might die due to parsing errors in some cases before it ever
- *       manages to call this function, such is life
- *
- * @see perldoc -f use
- *
- * @param string|int|float $req_ver The version to check, can be a string, an integer, or a float
- *
- * @deprecated since 1.30
- *
- * @throws MWException
- */
-function wfUsePHP( $req_ver ) {
-       wfDeprecated( __FUNCTION__, '1.30' );
-       $php_ver = PHP_VERSION;
-
-       if ( version_compare( $php_ver, (string)$req_ver, '<' ) ) {
-               throw new MWException( "PHP $req_ver required--this is only $php_ver" );
-       }
-}
-
 /**
  * Return the final portion of a pathname.
  * Reimplemented because PHP5's "basename()" is buggy with multibyte text.
@@ -3064,21 +3037,6 @@ function wfGetMessageCacheStorage() {
        return ObjectCache::getInstance( $wgMessageCacheType );
 }
 
-/**
- * Call hook functions defined in $wgHooks
- *
- * @param string $event Event name
- * @param array $args Parameters passed to hook functions
- * @param string|null $deprecatedVersion Optionally mark hook as deprecated with version number
- *
- * @return bool True if no handler aborted the hook
- * @deprecated since 1.25 - use Hooks::run
- */
-function wfRunHooks( $event, array $args = [], $deprecatedVersion = null ) {
-       wfDeprecated( __METHOD__, '1.25' );
-       return Hooks::run( $event, $args, $deprecatedVersion );
-}
-
 /**
  * Wrapper around php's unpack.
  *