27 lines
500 B
PHP
27 lines
500 B
PHP
<?php
|
|
|
|
namespace App\Controller;
|
|
|
|
use Phalcon\Mvc\Controller;
|
|
|
|
class ControllerBase extends Controller
|
|
{
|
|
/**
|
|
* Helper method to forward to the 404 - file not found page.
|
|
*/
|
|
protected function _forward404()
|
|
{
|
|
$this->dispatcher->forward(array(
|
|
'controller' => 'error',
|
|
'action' => 'show404'
|
|
));
|
|
}
|
|
|
|
/**
|
|
* @return Auth\Auth
|
|
*/
|
|
protected function _getAuth()
|
|
{
|
|
return $this->di->get('auth');
|
|
}
|
|
}
|