original_string: private function applyConfig($config)
      {
          try {
              if (isset($config['enabledLevels'])) {
                  $this->setEnabledLevels($config['enabledLevels']);
              } else {
                  $this->setEnabledLevels(['error', 'warning']);
              }
  
              if (isset($config['flushIntervals'])) {
                  $this->setFlushIntervals($config['flushIntervals']);
              } else {
                  $this->setFlushIntervals(100);
              }
  
              if (isset($config['targets'])) {
                  foreach ($config['targets'] as $key => $value) {
                      if (isset($value['class'])) {
                          $className = $value['class'];
                          $this->_targets[$key] = $className::build($value);
                      }
                  }
              }
          } catch (InvalidConfigurationException $e) {
              $configStr = print_r($config, true);
  
              error_log('Invalid Configuration for Logger Component. '.PHP_EOL.$configStr);
          }
      }
code: private function applyConfig($config)
      {
          try {
              if (isset($config['enabledLevels'])) {
                  $this->setEnabledLevels($config['enabledLevels']);
              } else {
                  $this->setEnabledLevels(['error', 'warning']);
              }
  
              if (isset($config['flushIntervals'])) {
                  $this->setFlushIntervals($config['flushIntervals']);
              } else {
                  $this->setFlushIntervals(100);
              }
  
              if (isset($config['targets'])) {
                  foreach ($config['targets'] as $key => $value) {
                      if (isset($value['class'])) {
                          $className = $value['class'];
                          $this->_targets[$key] = $className::build($value);
                      }
                  }
              }
          } catch (InvalidConfigurationException $e) {
              $configStr = print_r($config, true);
  
              error_log('Invalid Configuration for Logger Component. '.PHP_EOL.$configStr);
          }
      }
code_tokens: private function applyConfig ( $ config ) { try { if ( isset ( $ config [ 'enabledLevels' ] ) ) { $ this -> setEnabledLevels ( $ config [ 'enabledLevels' ] ) ; } else { $ this -> setEnabledLevels ( [ 'error' , 'warning' ] ) ; } if ( isset ( $ config [ 'flushIntervals' ] ) ) { $ this -> setFlushIntervals ( $ config [ 'flushIntervals' ] ) ; } else { $ this -> setFlushIntervals ( 100 ) ; } if ( isset ( $ config [ 'targets' ] ) ) { foreach ( $ config [ 'targets' ] as $ key => $ value ) { if ( isset ( $ value [ 'class' ] ) ) { $ className = $ value [ 'class' ] ; $ this -> _targets [ $ key ] = $ className :: build ( $ value ) ; } } } } catch ( InvalidConfigurationException $ e ) { $ configStr = print_r ( $ config , true ) ; error_log ( 'Invalid Configuration for Logger Component. ' . PHP_EOL . $ configStr ) ; } }
docstring: Applies log configuration
  @param array $config
docstring_tokens: Applies log configuration