3 namespace Drupal\module_install_class_loader_test1;
5 use Symfony\Component\EventDispatcher\EventSubscriberInterface;
8 * An event subscriber that does different things depending on whether classes
11 class EventSubscriber implements EventSubscriberInterface {
16 public static function getSubscribedEvents() {
18 // If the autoloader is not fixed during module install when the modules
19 // module_install_class_loader_test1 and module_install_class_loader_test2
20 // are enabled in the same request the class_exists() will cause a crash.
21 // This is because \Composer\Autoload\ClassLoader maintains a negative
23 if (class_exists('\Drupal\module_install_class_loader_test2\EventSubscriber')) {