function __construct() { if (!empty($_SESSION['user_login']) && !empty($_SESSION['user_id']) && $_SESSION['logged'] == 'logged') { parent::__construct(); $this->practice_model = new Practice_model(); $this->user_model = new User_model(); $this->view = new MA_View(); } else { header('Location: /login'); } }
function __construct() { parent::__construct(); $this->user_model = new User_model(); $this->view = new MA_View(); }