@@ -19,8 +19,7 @@ |
||
| 19 | 19 | { |
| 20 | 20 | $this->configureRateLimiting(); |
| 21 | 21 | |
| 22 | - $this->routes(function() |
|
| 23 | - { |
|
| 22 | + $this->routes(function() { |
|
| 24 | 23 | // Basic Login and Logout Routes |
| 25 | 24 | Route::middleware('web') |
| 26 | 25 | ->namespace($this->namespace) |
@@ -65,7 +65,8 @@ |
||
| 65 | 65 | $fileType = CustomerFileType::find($id); |
| 66 | 66 | $this->authorize('delete', $fileType); |
| 67 | 67 | |
| 68 | - try { |
|
| 68 | + try |
|
| 69 | + { |
|
| 69 | 70 | $fileType->delete(); |
| 70 | 71 | } |
| 71 | 72 | // The deletion may fail if the file type is currently in use |
@@ -36,8 +36,7 @@ |
||
| 36 | 36 | ->orderBy('sticky', 'DESC') |
| 37 | 37 | ->orderBy('created_at', 'DESC') |
| 38 | 38 | // Search text fields |
| 39 | - ->when($searchText, function($q) use($searchText) |
|
| 40 | - { |
|
| 39 | + ->when($searchText, function($q) use($searchText) { |
|
| 41 | 40 | foreach($searchText as $text) |
| 42 | 41 | { |
| 43 | 42 | $q->orWhere('subject', 'like', '%'.$text.'%') |
@@ -18,8 +18,10 @@ |
||
| 18 | 18 | { |
| 19 | 19 | $guards = empty($guards) ? [null] : $guards; |
| 20 | 20 | |
| 21 | - foreach($guards as $guard) { |
|
| 22 | - if(Auth::guard($guard)->check()) { |
|
| 21 | + foreach($guards as $guard) |
|
| 22 | + { |
|
| 23 | + if(Auth::guard($guard)->check()) |
|
| 24 | + { |
|
| 23 | 25 | return redirect(RouteServiceProvider::HOME); |
| 24 | 26 | } |
| 25 | 27 | } |
@@ -11,7 +11,8 @@ |
||
| 11 | 11 | */ |
| 12 | 12 | protected function redirectTo($request) |
| 13 | 13 | { |
| 14 | - if(!$request->expectsJson()) { |
|
| 14 | + if(!$request->expectsJson()) |
|
| 15 | + { |
|
| 15 | 16 | return route('login.index'); |
| 16 | 17 | } |
| 17 | 18 | } |