App\Controllers\Sites\UniversalPageController::homeAction PHP Method

homeAction() public method

public homeAction ( Psr\Http\Message\ServerRequestInterface $req, $res )
$req Psr\Http\Message\ServerRequestInterface
    public function homeAction(request $req, $res)
    {
        $store = $this->c->cache->store();
        if (!$store->has('controller.universal.homeAction')) {
            $this->data['pageData'] = PageFactory::getPageWithRequest($req);
            $ar = $this->data['pageData']->toArray();
            $store->put('controller.universal.homeAction', $ar, 60);
        } else {
            $this->data['pageData'] = $store->get('controller.universal.homeAction');
        }
        $this->setRequestResult($req, $res);
        $this->render('public\\main\\pages\\home.twig');
    }