Inheritance: extends Phalcon\Mvc\Controller
Example #1
0
 public function afterExecuteRoute($dispatcher)
 {
     if (!($cacheKey = $this->cacheKey)) {
         return parent::afterExecuteRoute($dispatcher);
     }
     $cache = $this->getDI()->getApiCache();
     $cache->save($cacheKey, $this->response->getContent(), $this->expired);
     return parent::afterExecuteRoute($dispatcher);
 }