aauth = new Aauth(); helper('aauth'); if (! $this->aauth->isLoggedIn()) { redirect()->to('/'); } } /** * Index * * @return void */ public function index() { $data['user'] = $this->aauth->getUser(); echo view('Templates/Header'); echo view('Account/Home', $data); echo view('Templates/Footer'); } }