Passed
Push — master ( 9f5635...6b9ecc )
by Paul
04:06
created
src/TinreServiceProvider.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -143,9 +143,9 @@  discard block
 block discarded – undo
143 143
 
144 144
     protected function registerTokenGuard()
145 145
     {
146
-        Auth::resolved(function ($auth) {
147
-            $auth->extend('token', function ($app, $name, array $config) {
148
-                return tap($this->makeTokenGuard(), function ($guard) {
146
+        Auth::resolved(function($auth) {
147
+            $auth->extend('token', function($app, $name, array $config) {
148
+                return tap($this->makeTokenGuard(), function($guard) {
149 149
                     $this->app->refresh('request', $guard, 'setRequest');
150 150
                 });
151 151
             });
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
 
155 155
     protected function makeTokenGuard()
156 156
     {
157
-        return new RequestGuard(function ($request) {
157
+        return new RequestGuard(function($request) {
158 158
             return (new TokenGuard(
159 159
                 $request
160 160
             ))->user();
Please login to merge, or discard this patch.
src/Traits/HasPermissions.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
     {
35 35
         $tokenPermissions = $accessToken->permissions;
36 36
 
37
-        if (! is_array($tokenPermissions)) {
37
+        if (!is_array($tokenPermissions)) {
38 38
             return [];
39 39
         }
40 40
 
Please login to merge, or discard this patch.
src/Http/Controllers/Web/StatsController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
             abort(401);
31 31
         }
32 32
 
33
-        if (! $user->hasPermissionTo('stats:view')) {
33
+        if (!$user->hasPermissionTo('stats:view')) {
34 34
             abort(401);
35 35
         }
36 36
 
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
             abort(401);
54 54
         }
55 55
 
56
-        if (! $user->hasPermissionTo('stats:view')) {
56
+        if (!$user->hasPermissionTo('stats:view')) {
57 57
             abort(401);
58 58
         }
59 59
 
Please login to merge, or discard this patch.
src/Policies/AccessTokenPolicy.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
             return true;
26 26
         }
27 27
 
28
-        if (! $user->hasPermissionTo('access_token:view')) {
28
+        if (!$user->hasPermissionTo('access_token:view')) {
29 29
             return false;
30 30
         }
31 31
 
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
             return true;
52 52
         }
53 53
 
54
-        if (! $user->hasPermissionTo('access_token:update')) {
54
+        if (!$user->hasPermissionTo('access_token:update')) {
55 55
             return false;
56 56
         }
57 57
 
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
             return true;
69 69
         }
70 70
 
71
-        if (! $user->hasPermissionTo('access_token:delete')) {
71
+        if (!$user->hasPermissionTo('access_token:delete')) {
72 72
             return false;
73 73
         }
74 74
 
Please login to merge, or discard this patch.
src/Http/Controllers/Web/AccessTokenController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
     {
15 15
         $user = $request->user();
16 16
 
17
-        if (! $user->hasAnyPermission(['access_token:view', 'access_token:view:any'])) {
17
+        if (!$user->hasAnyPermission(['access_token:view', 'access_token:view:any'])) {
18 18
             abort(401);
19 19
         }
20 20
 
Please login to merge, or discard this patch.
src/Http/Controllers/Api/V1/StatsController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
             abort(401);
31 31
         }
32 32
 
33
-        if (! $user->hasPermissionTo('stats:view')) {
33
+        if (!$user->hasPermissionTo('stats:view')) {
34 34
             abort(401);
35 35
         }
36 36
 
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
             abort(401);
54 54
         }
55 55
 
56
-        if (! $user->hasPermissionTo('stats:view')) {
56
+        if (!$user->hasPermissionTo('stats:view')) {
57 57
             abort(401);
58 58
         }
59 59
 
Please login to merge, or discard this patch.
src/Services/StatsService.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
 
33 33
     public function getData(string $column, int $urlId, string $startDate, string $endDate): object
34 34
     {
35
-        if (! in_array($column, ['country', 'region', 'city', 'device_type', 'device_brand', 'device_model', 'os', 'browser', 'referer', 'referer_host'])) {
35
+        if (!in_array($column, ['country', 'region', 'city', 'device_type', 'device_brand', 'device_model', 'os', 'browser', 'referer', 'referer_host'])) {
36 36
             throw ValidationException::withMessages([
37 37
                 'column' => [__('Unsupported column.')],
38 38
             ]);
Please login to merge, or discard this patch.
src/Http/Controllers/Api/V1/UrlController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
 
32 32
         $user = $request->user();
33 33
 
34
-        if (! $user->hasAnyPermission(['url:view', 'url:view:any'])) {
34
+        if (!$user->hasAnyPermission(['url:view', 'url:view:any'])) {
35 35
             abort(401);
36 36
         }
37 37
 
Please login to merge, or discard this patch.
src/Guards/TokenGuard.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -19,17 +19,17 @@
 block discarded – undo
19 19
         if ($token = $this->request->bearerToken()) {
20 20
             $accessToken = AccessToken::findToken($token);
21 21
 
22
-            if (! $accessToken) {
22
+            if (!$accessToken) {
23 23
                 return;
24 24
             }
25 25
 
26 26
             $user = $accessToken->user;
27 27
 
28
-            if (! $user->active) {
28
+            if (!$user->active) {
29 29
                 return;
30 30
             }
31 31
 
32
-            if (! $user->hasApiAccess()) {
32
+            if (!$user->hasApiAccess()) {
33 33
                 return;
34 34
             }
35 35
 
Please login to merge, or discard this patch.