Passed
Push — master ( bdbf41...020b56 )
by Innocent
03:17
created
database/migrations/2019_09_04_203237_create_comments_table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
      */
14 14
     public function up()
15 15
     {
16
-        Schema::create('fg_comments', function (Blueprint $table) {
16
+        Schema::create('fg_comments', function(Blueprint $table) {
17 17
             $table->string('id', 150);
18 18
             $table->string('creatable_id', 150)->index();
19 19
             $table->string('creatable_type');
Please login to merge, or discard this patch.
database/migrations/2019_09_04_201959_create_images_table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
      */
14 14
     public function up()
15 15
     {
16
-        Schema::create('fg_images', function (Blueprint $table) {
16
+        Schema::create('fg_images', function(Blueprint $table) {
17 17
             $table->string('id', 150);
18 18
             $table->string('imageable_id', 150)->index();
19 19
             $table->string('imageable_type');
Please login to merge, or discard this patch.
src/Models/Ministry.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     use CreatableTrait;
26 26
 
27 27
     protected $table = 'fg_ministries';
28
-    protected $guarded = ['id'];
28
+    protected $guarded = [ 'id' ];
29 29
     public $incrementing = false;
30 30
     protected $hidden = [
31 31
         'password',
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 
41 41
     public function getJWTCustomClaims()
42 42
     {
43
-        return [];
43
+        return [ ];
44 44
     }
45 45
 
46 46
     /**
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 
106 106
             return $phones;
107 107
         } else {
108
-            return [$this->phone];
108
+            return [ $this->phone ];
109 109
         }
110 110
     }
111 111
 
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
 
118 118
             return $emails;
119 119
         } else {
120
-            return [$this->email];
120
+            return [ $this->email ];
121 121
         }
122 122
     }
123 123
 
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
     public function getUsersAttribute()
143 143
     {
144 144
         return $this->ministryUsers()
145
-            ->map(fn ($minUser) => $minUser->user)
145
+            ->map(fn($minUser) => $minUser->user)
146 146
             ->flatten();
147 147
     }
148 148
 }
Please login to merge, or discard this patch.
src/Models/User.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
     use StorageTrait;
19 19
 
20 20
     protected $table = 'fg_users';
21
-    protected $guarded = ['id'];
21
+    protected $guarded = [ 'id' ];
22 22
     public $incrementing = false;
23 23
     protected $hidden = [
24 24
         'password',
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 
52 52
     public function getMinistriesAttribute()
53 53
     {
54
-        return Ministry::whereHas('ministryUsers', function ($minUser) {
54
+        return Ministry::whereHas('ministryUsers', function($minUser) {
55 55
             return $minUser->where('user_id', $this->id);
56 56
         });
57 57
     }
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     public function getActiveAttribute(): bool
60 60
     {
61 61
         if ($user = $this->ministryUsers()->where('ministry_id', auth()->user()->id)->first()) {
62
-            return (bool) $user->active;
62
+            return (bool)$user->active;
63 63
         }
64 64
 
65 65
         return false;
@@ -80,6 +80,6 @@  discard block
 block discarded – undo
80 80
 
81 81
     public function getImageDimensions()
82 82
     {
83
-        return [0, 50];
83
+        return [ 0, 50 ];
84 84
     }
85 85
 }
Please login to merge, or discard this patch.
src/Models/Ministry/Review.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,5 +10,5 @@
 block discarded – undo
10 10
     use BelongsToMinistryTrait;
11 11
 
12 12
     protected $table = 'fg_reviews';
13
-    protected $guarded = ['id'];
13
+    protected $guarded = [ 'id' ];
14 14
 }
Please login to merge, or discard this patch.
database/factories/MinistryFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
 use FaithGen\SDK\Models\Ministry;
6 6
 use Faker\Generator as Faker;
7 7
 
8
-$factory->define(Ministry::class, function (Faker $faker) {
8
+$factory->define(Ministry::class, function(Faker $faker) {
9 9
     return [
10 10
         'name'     => $faker->company,
11 11
         'email'    => $faker->safeEmail,
Please login to merge, or discard this patch.
database/factories/UserFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
 use FaithGen\SDK\Models\User;
6 6
 use Faker\Generator as Faker;
7 7
 
8
-$factory->define(User::class, function (Faker $faker) {
8
+$factory->define(User::class, function(Faker $faker) {
9 9
     return [
10 10
         //
11 11
     ];
Please login to merge, or discard this patch.
src/FaithGenSDKServiceProvider.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -23,32 +23,32 @@  discard block
 block discarded – undo
23 23
         $this->registerUserAuthRoutes();
24 24
 
25 25
         if ($this->app->runningInConsole()) {
26
-            $this->loadMigrationsFrom(__DIR__.'/../database/migrations');
26
+            $this->loadMigrationsFrom(__DIR__ . '/../database/migrations');
27 27
 
28 28
             $this->publishes([
29
-                __DIR__.'/../config/faithgen-sdk.php' => config_path('faithgen-sdk.php'),
29
+                __DIR__ . '/../config/faithgen-sdk.php' => config_path('faithgen-sdk.php'),
30 30
             ], 'faithgen-sdk-config');
31 31
 
32
-            $this->setUpSourceFiles(function () {
32
+            $this->setUpSourceFiles(function() {
33 33
                 $this->publishes([
34
-                    __DIR__.'/../database/migrations/' => database_path('migrations'),
34
+                    __DIR__ . '/../database/migrations/' => database_path('migrations'),
35 35
                 ], 'faithgen-sdk-migrations');
36 36
 
37 37
                 $this->publishes([
38
-                    __DIR__.'/../storage/profile/' => storage_path('app/public/profile'),
38
+                    __DIR__ . '/../storage/profile/' => storage_path('app/public/profile'),
39 39
                 ], 'faithgen-sdk-storage');
40 40
             });
41 41
 
42
-            if (! config('faithgen-sdk.source')) {
42
+            if (!config('faithgen-sdk.source')) {
43 43
                 $this->publishes([
44
-                    __DIR__.'/../storage/users/' => storage_path('app/public/users'),
44
+                    __DIR__ . '/../storage/users/' => storage_path('app/public/users'),
45 45
                 ], 'faithgen-sdk-storage');
46 46
 
47
-                $this->loadFactoriesFrom(__DIR__.'/../database/factories');
47
+                $this->loadFactoriesFrom(__DIR__ . '/../database/factories');
48 48
             }
49 49
 
50 50
             $this->publishes([
51
-                __DIR__.'/../storage/logo/' => public_path('images'),
51
+                __DIR__ . '/../storage/logo/' => public_path('images'),
52 52
             ], 'faithgen-logo');
53 53
         }
54 54
 
@@ -72,8 +72,8 @@  discard block
 block discarded – undo
72 72
 
73 73
     private function registerApiRoutes()
74 74
     {
75
-        Route::group($this->apiRouteConfiguration(), function () {
76
-            $this->loadRoutesFrom(__DIR__.'/../routes/api.php');
75
+        Route::group($this->apiRouteConfiguration(), function() {
76
+            $this->loadRoutesFrom(__DIR__ . '/../routes/api.php');
77 77
         });
78 78
     }
79 79
 
@@ -93,13 +93,13 @@  discard block
 block discarded – undo
93 93
     private function registerParentRoutes()
94 94
     {
95 95
         if (config('faithgen-sdk.source')) {
96
-            Route::group($this->parentRouteConfiguration(), function () {
97
-                $this->loadRoutesFrom(__DIR__.'/../routes/source.php');
96
+            Route::group($this->parentRouteConfiguration(), function() {
97
+                $this->loadRoutesFrom(__DIR__ . '/../routes/source.php');
98 98
             });
99 99
 
100 100
             $this->registerAuthRoutes();
101 101
 
102
-            $this->loadRoutesFrom(__DIR__.'/../routes/web.php');
102
+            $this->loadRoutesFrom(__DIR__ . '/../routes/web.php');
103 103
         }
104 104
     }
105 105
 
@@ -107,21 +107,21 @@  discard block
 block discarded – undo
107 107
     {
108 108
         return [
109 109
             'prefix'     => config('faithgen-sdk.prefix'),
110
-            'middleware' => ['bindings'],
110
+            'middleware' => [ 'bindings' ],
111 111
         ];
112 112
     }
113 113
 
114 114
     private function registerAuthRoutes()
115 115
     {
116
-        Route::group($this->authRouteConfiguration(), function () {
117
-            $this->loadRoutesFrom(__DIR__.'/../routes/auth.php');
116
+        Route::group($this->authRouteConfiguration(), function() {
117
+            $this->loadRoutesFrom(__DIR__ . '/../routes/auth.php');
118 118
         });
119 119
     }
120 120
 
121 121
     private function registerUserAuthRoutes()
122 122
     {
123
-        Route::group($this->authRouteConfiguration(), function () {
124
-            $this->loadRoutesFrom(__DIR__.'/../routes/users-auth.php');
123
+        Route::group($this->authRouteConfiguration(), function() {
124
+            $this->loadRoutesFrom(__DIR__ . '/../routes/users-auth.php');
125 125
         });
126 126
     }
127 127
 
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
      */
133 133
     public function register()
134 134
     {
135
-        $this->mergeConfigFrom(__DIR__.'/../config/faithgen-sdk.php', 'faithgen-sdk');
135
+        $this->mergeConfigFrom(__DIR__ . '/../config/faithgen-sdk.php', 'faithgen-sdk');
136 136
 
137 137
         $this->app->singleton(ProfileService::class);
138 138
         $this->app->singleton(ImageService::class);
Please login to merge, or discard this patch.
routes/auth.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -5,13 +5,13 @@
 block discarded – undo
5 5
 
6 6
 Route::prefix('auth/')
7 7
     ->name('auth.')
8
-    ->group(function () {
9
-        Route::post('register', [AuthController::class, 'register'])->name('register');
10
-        Route::post('login', [AuthController::class, 'login'])->name('login');
11
-        Route::post('forgot-password', [AuthController::class, 'forgotPassword'])->name('forgotPassword');
12
-        Route::get('resend-activation', [AuthController::class, 'resendActivation'])->name('resendActivation')
8
+    ->group(function() {
9
+        Route::post('register', [ AuthController::class, 'register' ])->name('register');
10
+        Route::post('login', [ AuthController::class, 'login' ])->name('login');
11
+        Route::post('forgot-password', [ AuthController::class, 'forgotPassword' ])->name('forgotPassword');
12
+        Route::get('resend-activation', [ AuthController::class, 'resendActivation' ])->name('resendActivation')
13 13
             ->middleware('auth:api');
14
-        Route::delete('delete-account', [AuthController::class, 'deleteAccount'])->name('deleteAccount')
14
+        Route::delete('delete-account', [ AuthController::class, 'deleteAccount' ])->name('deleteAccount')
15 15
             ->middleware('auth:api');
16
-        Route::get('logout', [AuthController::class, 'logout'])->name('logout')->middleware('auth:api');
16
+        Route::get('logout', [ AuthController::class, 'logout' ])->name('logout')->middleware('auth:api');
17 17
     });
Please login to merge, or discard this patch.