Completed
Push — ports_ajax ( cdec2c )
by Tony
06:36
created
app/Http/Middleware/Authenticate.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,8 @@
 block discarded – undo
20 20
         if (Auth::guard($guard)->guest()) {
21 21
             if ($request->ajax() || $request->wantsJson()) {
22 22
                 return response('Unauthorized.', 401);
23
-            } else {
23
+            }
24
+            else {
24 25
                 return redirect()->guest('login');
25 26
             }
26 27
         }
Please login to merge, or discard this patch.
app/Http/Controllers/PortController.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
 //        return view('ports.list', ['ports'=>$ports]);
34 34
 
35 35
         // FIXME: is this correct?
36
-	$token = JWTAuth::fromUser(auth()->user());
36
+    $token = JWTAuth::fromUser(auth()->user());
37 37
         $ports = []; // empty table
38 38
 
39 39
         return view('ports.list', ['ports'=>$port, 'token'=>$token]);
Please login to merge, or discard this patch.