user = $user; } public function index() { return $this->user->all(); } public function show($id) { return $this->user->findOrFail($id); } public function edit($id) { return $this->response->noContent(); } public function store() { try { $this->user->email = Input::get('email'); $this->user->password = Hash::make(Input::get('password')); if ($this->user->save()) { return $this->response->created(); } else { throw new Dingo\Api\Exception\StoreResourceFailedException; } } catch (Exception $e) { throw new Dingo\Api\Exception\StoreResourceFailedException; } } }