public function cacheImageAction() { /** @var Events $event */ $event = Events::findFirst(['(type = :type1: OR type = :type2:) AND state = :state:', 'bind' => ['type1' => Events::CACHE_IMAGE_AFTER_PARTIAL_UPDATE, 'type2' => Events::CACHE_IMAGE_AFTER_FULL_UPDATE, 'state' => Events::OPEN], 'order' => 'created_at ASC']); if ($event) { return $event->processCacheImage($this); } return false; }