Merge "Fix \n handling for HTMLUsersMultiselectField"
[lhc/web/wiklou.git] / includes / debug / logger / LoggerFactory.php
index b0a10ce..c183ff1 100644 (file)
@@ -40,8 +40,7 @@ use ObjectFactory;
  *
  * @see \MediaWiki\Logger\Spi
  * @since 1.25
- * @author Bryan Davis <bd808@wikimedia.org>
- * @copyright © 2014 Bryan Davis and Wikimedia Foundation.
+ * @copyright © 2014 Wikimedia Foundation and contributors
  */
 class LoggerFactory {
 
@@ -51,7 +50,6 @@ class LoggerFactory {
         */
        private static $spi;
 
-
        /**
         * Register a service provider to create new \Psr\Log\LoggerInterface
         * instances.
@@ -62,7 +60,6 @@ class LoggerFactory {
                self::$spi = $provider;
        }
 
-
        /**
         * Get the registered service provider.
         *
@@ -86,7 +83,6 @@ class LoggerFactory {
                return self::$spi;
        }
 
-
        /**
         * Get a named logger instance from the currently configured logger factory.
         *
@@ -94,28 +90,9 @@ class LoggerFactory {
         * @return \Psr\Log\LoggerInterface
         */
        public static function getInstance( $channel ) {
-               static $hasPSR3Interface = null;
-               if ( $hasPSR3Interface === null ) {
-                       $hasPSR3Interface = interface_exists( 'Psr\Log\LoggerInterface' );
-                       if ( !$hasPSR3Interface ) {
-                               $message = (
-                                       'MediaWiki requires the <a href="https://github.com/php-fig/log">PSR-3 logging ' .
-                                       "library</a> to be present. This library is not embedded directly in MediaWiki's " .
-                                       "git repository and must be installed separately by the end user.\n\n" .
-                                       'Please see <a href="https://www.mediawiki.org/wiki/Download_from_Git' .
-                                       '#Fetch_external_libraries">mediawiki.org</a> for help on installing ' .
-                                       'the required components.'
-                               );
-                               echo $message;
-                               trigger_error( $message, E_USER_ERROR );
-                               die( 1 );
-                       }
-               }
-
                return self::getProvider()->getLogger( $channel );
        }
 
-
        /**
         * Construction of utility class is not allowed.
         */