X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2FGlobalFunctions.php;h=c769b0ab3f168253a316d20e50bd1da91c463154;hp=4f121107e2977f412aeaaa785229560fc02cfcb8;hb=2323b0ba8161892714c3aba9fc6a4212397e0283;hpb=52a4ffbf42c22af74e5883578cd503979781a5cb diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index 4f121107e2..c769b0ab3f 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -1147,26 +1147,6 @@ function wfLogWarning( $msg, $callerOffset = 1, $level = E_USER_WARNING ) { MWDebug::warning( $msg, $callerOffset + 1, $level, 'production' ); } -/** - * Log to a file without getting "file size exceeded" signals. - * - * Can also log to TCP or UDP with the syntax udp://host:port/prefix. This will - * send lines to the specified port, prefixed by the specified prefix and a space. - * @since 1.25 support for additional context data - * - * @param string $text - * @param string $file Filename - * @param array $context Additional logging context data - * @throws MWException - * @deprecated since 1.25 Use \MediaWiki\Logger\LegacyLogger::emit or UDPTransport - */ -function wfErrorLog( $text, $file, array $context = [] ) { - wfDeprecated( __METHOD__, '1.25' ); - $logger = LoggerFactory::getInstance( 'wfErrorLog' ); - $context['destination'] = $file; - $logger->info( trim( $text ), $context ); -} - /** * @todo document * @todo Move logic to MediaWiki.php @@ -2503,38 +2483,6 @@ function wfUsePHP( $req_ver ) { } } -/** - * This function works like "use VERSION" in Perl except it checks the version - * of MediaWiki, the program will die with a backtrace if the current version - * of MediaWiki is less than the version provided. - * - * This is useful for extensions which due to their nature are not kept in sync - * with releases - * - * Note: Due to the behavior of PHP's version_compare() which is used in this - * function, if you want to allow the 'wmf' development versions add a 'c' (or - * any single letter other than 'a', 'b' or 'p') as a post-fix to your - * targeted version number. For example if you wanted to allow any variation - * of 1.22 use `wfUseMW( '1.22c' )`. Using an 'a' or 'b' instead of 'c' will - * not result in the same comparison due to the internal logic of - * version_compare(). - * - * @see perldoc -f use - * - * @deprecated since 1.26, use the "requires" property of extension.json - * @param string|int|float $req_ver The version to check, can be a string, an integer, or a float - * @throws MWException - */ -function wfUseMW( $req_ver ) { - global $wgVersion; - - wfDeprecated( __FUNCTION__, '1.26' ); - - if ( version_compare( $wgVersion, (string)$req_ver, '<' ) ) { - throw new MWException( "MediaWiki $req_ver required--this is only $wgVersion" ); - } -} - /** * Return the final portion of a pathname. * Reimplemented because PHP5's "basename()" is buggy with multibyte text.