You are here

class RequestUriProcessor in Monolog 8

Same name and namespace in other branches
  1. 2.x src/Logger/Processor/RequestUriProcessor.php \Drupal\monolog\Logger\Processor\RequestUriProcessor

Class RequestUriProcessor.php

Hierarchy

Expanded class hierarchy of RequestUriProcessor

1 string reference to 'RequestUriProcessor'
monolog.services.yml in ./monolog.services.yml
monolog.services.yml
1 service uses RequestUriProcessor
monolog.processor.request_uri in ./monolog.services.yml
Drupal\monolog\Logger\Processor\RequestUriProcessor

File

src/Logger/Processor/RequestUriProcessor.php, line 8

Namespace

Drupal\monolog\Logger\Processor
View source
class RequestUriProcessor extends AbstractRequestProcessor {

  /**
   * @param array $record
   *
   * @return array
   */
  public function __invoke(array $record) {
    if ($request = $this
      ->getRequest()) {
      $record['extra']['request_uri'] = $request
        ->getUri();
    }
    return $record;
  }

}

Members