class InitSubscriber in Lightbox2 8
Hierarchy
- class \Drupal\lightbox2\EventSubscriber\InitSubscriber implements \Symfony\Component\EventDispatcher\EventSubscriberInterface
Expanded class hierarchy of InitSubscriber
1 string reference to 'InitSubscriber'
1 service uses InitSubscriber
File
- src/
EventSubscriber/ InitSubscriber.php, line 11 - Contains \Drupal\lightbox2\EventSubscriber\InitSubscriber.
Namespace
Drupal\lightbox2\EventSubscriberView source
class InitSubscriber implements EventSubscriberInterface {
/**
* {@inheritdoc}
*/
public static function getSubscribedEvents() {
return [
KernelEvents::REQUEST => [
'onEvent',
0,
],
];
}
public function onEvent() {
if (lightbox2_exclude_these_paths() != 1) {
lightbox2_add_files();
}
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
InitSubscriber:: |
public static | function | Returns an array of event names this subscriber wants to listen to. | |
InitSubscriber:: |
public | function |