/**
* Process the edit form
*
* @author Steve Montambeault
* @link http://stevemo.ca
*
* @param $id
*
* @return \Illuminate\Http\RedirectResponse
*/
public function update($id)
{
$inputs = Input::all();
$inputs['id'] = $id;
try {
if ($this->form->update($inputs)) {
return Redirect::route('cpanel.permissions.index')->with('success', Lang::get('cpanel::permissions.update_success'));
}
return Redirect::back()->withInput()->withErrors($this->form->getErrors());
} catch (PermissionNotFoundException $e) {
return Redirect::route('cpanel.permissions.index')->with('error', Lang::get('cpanel::permissions.model_not_found'));
}
}