public function add() { $author = Authors::create($this->request->data); if ($this->request->data && $author->save()) { Session::write('message', 'Your author account has been created'); return $this->redirect('Authors::dashboard'); } else { Session::write('message', 'Your author can not be created'); } return compact('author'); }