src/Sources/AbstractSource.php
public final function setLogger( ?LoggerInterface $logger )
   {

      $this->_options[ 'logger' ] = null === $logger ? new NullLogger() : $logger;

      unset( $this->_options[ 'data' ] );

      return $this;

   }
public final function setLogger( ?LoggerInterface $logger )
   {

      $this->_options[ 'logger' ] = null === $logger ? new NullLogger() : $logger;

      unset( $this->_options[ 'data' ] );

      return $this;

   }
public final function setLogger ( ? LoggerInterface $ logger ) { $ this -> _options [ 'logger' ] = null === $ logger ? new NullLogger ( ) : $ logger ; unset ( $ this -> _options [ 'data' ] ) ; return $ this ; }
Sets a new logger or null if no logger should be used.

@param \Psr\Log\LoggerInterface|null $logger
@return \Niirrty\Translation\Sources\ISource
Sets a new logger or null if no logger should be used .