Passed
Push — master ( f218e6...f51c1b )
by Arthur
04:59
created
src/Modules/Notification/Routes/api.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -13,9 +13,9 @@
 block discarded – undo
13 13
 
14 14
 use Modules\Authorization\Entities\Permission;
15 15
 
16
-Route::get('/{id}', 'MachineController@show')->middleware(['permission:'.Permission::SHOW_MACHINE]);
17
-Route::patch('/{id}', 'MachineController@update')->middleware(['permission:'.Permission::UPDATE_MACHINE]);
18
-Route::delete('/{id}', 'MachineController@destroy')->middleware(['permission:'.Permission::DELETE_MACHINE]);
16
+Route::get('/{id}', 'MachineController@show')->middleware([ 'permission:'.Permission::SHOW_MACHINE ]);
17
+Route::patch('/{id}', 'MachineController@update')->middleware([ 'permission:'.Permission::UPDATE_MACHINE ]);
18
+Route::delete('/{id}', 'MachineController@destroy')->middleware([ 'permission:'.Permission::DELETE_MACHINE ]);
19 19
 
20
-Route::post('/', 'MachineController@store')->middleware(['permission:'.Permission::CREATE_MACHINE]);
21
-Route::get('/', 'MachineController@index')->middleware(['permission:'.Permission::SHOW_MACHINE]);
20
+Route::post('/', 'MachineController@store')->middleware([ 'permission:'.Permission::CREATE_MACHINE ]);
21
+Route::get('/', 'MachineController@index')->middleware([ 'permission:'.Permission::SHOW_MACHINE ]);
Please login to merge, or discard this patch.
Modules/User/Database/Migrations/2018_10_04_134544_CreateUserMigration.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
      */
13 13
     public function up()
14 14
     {
15
-        Schema::create('users', function (Blueprint $table) {
15
+        Schema::create('users', function(Blueprint $table) {
16 16
             $table->increments('id');
17 17
             $table->string('identity_id')->unique();
18 18
             $table->string('email');
Please login to merge, or discard this patch.
src/Modules/User/Services/UserService.php 1 patch
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -22,13 +22,15 @@
 block discarded – undo
22 22
 
23 23
     public function find($id): ?User
24 24
     {
25
-        if ($id instanceof User)
26
-            return $id;
25
+        if ($id instanceof User) {
26
+                    return $id;
27
+        }
27 28
 
28 29
         $user = User::find($id);
29 30
 
30
-        if ($user === null)
31
-            throw new NotFoundHttpException();
31
+        if ($user === null) {
32
+                    throw new NotFoundHttpException();
33
+        }
32 34
 
33 35
         return $user;
34 36
     }
Please login to merge, or discard this patch.
src/Modules/Auth0/Services/Auth0Service.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 
48 48
     public function getUserByUserInfo($userInfo)
49 49
     {
50
-        return $this->upsertUser($userInfo['profile']);
50
+        return $this->upsertUser($userInfo[ 'profile' ]);
51 51
     }
52 52
 
53 53
     protected function upsertUser($profile)
@@ -56,8 +56,8 @@  discard block
 block discarded – undo
56 56
             throw new BadRequestHttpException('Missing token information: Auth0 user id is not set');
57 57
         }
58 58
         $identifier = explode('|', $profile->user_id);
59
-        $identityProvider = $identifier[0];
60
-        $id = $identifier[1];
59
+        $identityProvider = $identifier[ 0 ];
60
+        $id = $identifier[ 1 ];
61 61
 
62 62
         $user = $this->service->findByIdentityId($id);
63 63
         if ($user === null) {
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
 
94 94
     public function getTestUserToken(): \stdClass
95 95
     {
96
-        return Cache::remember('testing:http_access_token', 60, function () {
96
+        return Cache::remember('testing:http_access_token', 60, function() {
97 97
             try {
98 98
                 $httpClient = new Client();
99 99
                 $response = $httpClient->post(env('AUTH0_DOMAIN').'oauth/token', [
Please login to merge, or discard this patch.
src/Foundation/Console/DemoSeedCommand.php 2 patches
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -38,23 +38,23 @@  discard block
 block discarded – undo
38 38
      */
39 39
     public function handle()
40 40
     {
41
-        Model::unguarded(function () {
41
+        Model::unguarded(function() {
42 42
             $seeders = $this->getSeeders();
43 43
 
44
-            $priorities = [];
45
-            $prioritySeeders = [];
46
-            $nonPrioritySeeders = [];
44
+            $priorities = [ ];
45
+            $prioritySeeders = [ ];
46
+            $nonPrioritySeeders = [ ];
47 47
             foreach ($seeders as $seeder) {
48 48
                 $priority = get_class_property($seeder, 'priority');
49 49
                 if (!is_int($priority) && $priority !== null) {
50 50
                     throw new Exception('Priority on seeder must be integer');
51 51
                 } elseif ($priority !== null && in_array($priority, $priorities)) {
52
-                    throw new Exception("Duplicate priority on seeder $seeder with $prioritySeeders[$priority]");
52
+                    throw new Exception("Duplicate priority on seeder $seeder with $prioritySeeders[ $priority ]");
53 53
                 } elseif ($priority === null) {
54
-                    $nonPrioritySeeders[] = $seeder;
54
+                    $nonPrioritySeeders[ ] = $seeder;
55 55
                 } else {
56
-                    $priorities[] = $priority;
57
-                    $prioritySeeders[$priority] = $seeder;
56
+                    $priorities[ ] = $priority;
57
+                    $prioritySeeders[ $priority ] = $seeder;
58 58
                 }
59 59
             }
60 60
             ksort($prioritySeeders);
@@ -75,6 +75,6 @@  discard block
 block discarded – undo
75 75
     {
76 76
         $this->service = $this->laravel->make(BootstrapRegistrarService::class);
77 77
 
78
-        return $this->service->getSeeders() ?? [];
78
+        return $this->service->getSeeders() ?? [ ];
79 79
     }
80 80
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -63,8 +63,9 @@
 block discarded – undo
63 63
             foreach ($seeders as $seeder) {
64 64
                 $seeder = $this->laravel->make($seeder);
65 65
                 $seeder->__invoke();
66
-                if (class_implements_interface($seeder, DemoSeederContract::class))
67
-                    $seeder->runDemo();
66
+                if (class_implements_interface($seeder, DemoSeederContract::class)) {
67
+                                    $seeder->runDemo();
68
+                }
68 69
             }
69 70
         });
70 71
 
Please login to merge, or discard this patch.