Apply fixes from StyleCI (#351)

This commit is contained in:
Dane Everitt 2017-03-15 20:53:49 -04:00 committed by GitHub
parent 1c47b2ed55
commit 436ba814a9
2 changed files with 7 additions and 8 deletions

View file

@ -102,7 +102,7 @@ class PackController extends Controller
Alert::success('Pack successfully created on the system.')->flash(); Alert::success('Pack successfully created on the system.')->flash();
return redirect()->route('admin.packs.view', $pack->id); return redirect()->route('admin.packs.view', $pack->id);
} catch(DisplayValidationException $ex) { } catch (DisplayValidationException $ex) {
return redirect()->route('admin.packs.new')->withErrors(json_decode($ex->getMessage()))->withInput(); return redirect()->route('admin.packs.new')->withErrors(json_decode($ex->getMessage()))->withInput();
} catch (DisplayException $ex) { } catch (DisplayException $ex) {
Alert::danger($ex->getMessage())->flash(); Alert::danger($ex->getMessage())->flash();
@ -144,7 +144,7 @@ class PackController extends Controller
if ($request->input('action') !== 'delete') { if ($request->input('action') !== 'delete') {
$pack = $repo->update($id, $request->intersect([ $pack = $repo->update($id, $request->intersect([
'name', 'description', 'version', 'name', 'description', 'version',
'option_id', 'selectable', 'visible', 'locked' 'option_id', 'selectable', 'visible', 'locked',
])); ]));
Alert::success('Pack successfully updated.')->flash(); Alert::success('Pack successfully updated.')->flash();
} else { } else {
@ -153,7 +153,7 @@ class PackController extends Controller
return redirect()->route('admin.packs'); return redirect()->route('admin.packs');
} }
} catch(DisplayValidationException $ex) { } catch (DisplayValidationException $ex) {
return redirect()->route('admin.packs.view', $id)->withErrors(json_decode($ex->getMessage())); return redirect()->route('admin.packs.view', $id)->withErrors(json_decode($ex->getMessage()));
} catch (DisplayException $ex) { } catch (DisplayException $ex) {
Alert::danger($ex->getMessage())->flash(); Alert::danger($ex->getMessage())->flash();
@ -211,5 +211,4 @@ class PackController extends Controller
])->deleteFileAfterSend(true); ])->deleteFileAfterSend(true);
} }
} }
} }