/**
  * Ends the contrexx caching after the main template got parsed (frontend only)
  * @param string $endcode The processed data to be sent to the client as response
  */
 public function postFinalize(&$endcode)
 {
     if ($this->cx->getMode() != \Cx\Core\Core\Controller\Cx::MODE_FRONTEND) {
         return;
     }
     $page = $this->cx->getPage();
     if (!$page) {
         $page = \Env::get('Page');
     }
     $endcode = $this->cache->endContrexxCaching($page, $endcode);
 }