20240412#2

This commit is contained in:
User
2024-04-12 03:24:10 +03:00
parent c2d2ad9177
commit a35a50eb53
2 changed files with 4 additions and 7 deletions

View File

@@ -1,12 +1,11 @@
<?php <?php
namespace App\Main\Controllers; namespace App\Main\Controllers;
use App\Common\Controllers\AbstractController; use App\Common\Controllers\AbstractPageController;
use App\Common\Services\ServiceException;
use Psr\Http\Message\ResponseInterface; use Psr\Http\Message\ResponseInterface;
class IndexController extends AbstractController { class IndexController extends AbstractPageController {
/** /**
* @return bool|ResponseInterface * @return bool|ResponseInterface
@@ -18,10 +17,8 @@ class IndexController extends AbstractController {
$this->template()->setSubtemplate("main", "/main/index.tpl", [ $this->template()->setSubtemplate("main", "/main/index.tpl", [
"date" => (new \DateTime())->format('Y-m-d H:i:s') "date" => (new \DateTime())->format('Y-m-d H:i:s')
]); ]);
return $this->render();
} }
catch(ServiceException $exception){} catch(\Throwable $e){$error = $this->checkError($e);}
return true; return $this->render();
} }
} }