function OptionsRequestSubscriber::getSubscribedEvents

Same name in other branches
  1. 9 core/lib/Drupal/Core/EventSubscriber/OptionsRequestSubscriber.php \Drupal\Core\EventSubscriber\OptionsRequestSubscriber::getSubscribedEvents()
  2. 8.9.x core/lib/Drupal/Core/EventSubscriber/OptionsRequestSubscriber.php \Drupal\Core\EventSubscriber\OptionsRequestSubscriber::getSubscribedEvents()
  3. 10 core/lib/Drupal/Core/EventSubscriber/OptionsRequestSubscriber.php \Drupal\Core\EventSubscriber\OptionsRequestSubscriber::getSubscribedEvents()

File

core/lib/Drupal/Core/EventSubscriber/OptionsRequestSubscriber.php, line 64

Class

OptionsRequestSubscriber
Handles options requests.

Namespace

Drupal\Core\EventSubscriber

Code

public static function getSubscribedEvents() : array {
    // Set a high priority so it is executed before routing.
    $events[KernelEvents::REQUEST][] = [
        'onRequest',
        1000,
    ];
    return $events;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.