public function onPreRun(PreRunEvent $event) { if (count($event->getStatements()) > 0) { $this->hookedPreRun = true; } }