Merge "mw.Upload.BookletLayout: Handle additional warnings/errors"
[lhc/web/wiklou.git] / includes / debug / logger / MonologSpi.php
index 685abe0..49ad9e6 100644 (file)
@@ -126,16 +126,14 @@ class MonologSpi implements Spi {
         */
        protected $config;
 
-
        /**
         * @param array $config Configuration data.
         */
        public function __construct( array $config ) {
-               $this->config = array();
+               $this->config = [];
                $this->mergeConfig( $config );
        }
 
-
        /**
         * Merge additional configuration data into the configuration.
         *
@@ -153,7 +151,6 @@ class MonologSpi implements Spi {
                $this->reset();
        }
 
-
        /**
         * Reset internal caches.
         *
@@ -161,15 +158,14 @@ class MonologSpi implements Spi {
         * be no need to flush the caches.
         */
        public function reset() {
-               $this->singletons = array(
-                       'loggers'    => array(),
-                       'handlers'   => array(),
-                       'formatters' => array(),
-                       'processors' => array(),
-               );
+               $this->singletons = [
+                       'loggers'    => [],
+                       'handlers'   => [],
+                       'formatters' => [],
+                       'processors' => [],
+               ];
        }
 
-
        /**
         * Get a logger instance.
         *
@@ -178,7 +174,7 @@ class MonologSpi implements Spi {
         * name will return the cached instance.
         *
         * @param string $channel Logging channel
-        * @return \\Psr\\Log\\LoggerInterface Logger instance
+        * @return \Psr\Log\LoggerInterface Logger instance
         */
        public function getLogger( $channel ) {
                if ( !isset( $this->singletons['loggers'][$channel] ) ) {
@@ -195,19 +191,18 @@ class MonologSpi implements Spi {
                return $this->singletons['loggers'][$channel];
        }
 
-
        /**
         * Create a logger.
         * @param string $channel Logger channel
         * @param array $spec Configuration
-        * @return \\Monolog\\Logger
+        * @return \Monolog\Logger
         */
        protected function createLogger( $channel, $spec ) {
                $obj = new Logger( $channel );
 
                if ( isset( $spec['calls'] ) ) {
                        foreach ( $spec['calls'] as $method => $margs ) {
-                               call_user_func_array( array( $obj, $method ), $margs );
+                               call_user_func_array( [ $obj, $method ], $margs );
                        }
                }
 
@@ -225,7 +220,6 @@ class MonologSpi implements Spi {
                return $obj;
        }
 
-
        /**
         * Create or return cached processor.
         * @param string $name Processor name
@@ -240,11 +234,10 @@ class MonologSpi implements Spi {
                return $this->singletons['processors'][$name];
        }
 
-
        /**
         * Create or return cached handler.
         * @param string $name Processor name
-        * @return \\Monolog\\Handler\\HandlerInterface
+        * @return \Monolog\Handler\HandlerInterface
         */
        public function getHandler( $name ) {
                if ( !isset( $this->singletons['handlers'][$name] ) ) {
@@ -263,11 +256,10 @@ class MonologSpi implements Spi {
                return $this->singletons['handlers'][$name];
        }
 
-
        /**
         * Create or return cached formatter.
         * @param string $name Formatter name
-        * @return \\Monolog\\Formatter\\FormatterInterface
+        * @return \Monolog\Formatter\FormatterInterface
         */
        public function getFormatter( $name ) {
                if ( !isset( $this->singletons['formatters'][$name] ) ) {