Passed
Pull Request — master (#1298)
by
unknown
05:25
created
app/Logic/Activation/ActivationRepository.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -75,13 +75,13 @@
 block discarded – undo
75 75
     }
76 76
 
77 77
 
78
-     /**
79
-     * Creates a token and send email.- api
80
-     *
81
-     * @param \App\Models\User $user
82
-     *
83
-     * @return bool or void
84
-     */
78
+        /**
79
+         * Creates a token and send email.- api
80
+         *
81
+         * @param \App\Models\User $user
82
+         *
83
+         * @return bool or void
84
+         */
85 85
     public function createTokenAndSendEmailApi(User $user)
86 86
     {
87 87
         $activations = Activation::where('user_id', $user->id)
Please login to merge, or discard this patch.
app/Jobs/Tenant/Migration.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,12 +31,12 @@
 block discarded – undo
31 31
      *
32 32
      * @return void
33 33
      */
34
-    public function __construct(Company $tenant, $name='', $email='', $password='')
34
+    public function __construct(Company $tenant, $name = '', $email = '', $password = '')
35 35
     {
36 36
         //
37 37
         $this->tenant = $tenant;
38 38
         $this->name = $name;
39
-        $this->email= $email;
39
+        $this->email = $email;
40 40
         $this->password = $password;
41 41
         // $this->queue = 'sync';
42 42
     }
Please login to merge, or discard this patch.
app/Service/MixedConnection.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
 {
10 10
     public static function set($user, $tenant)
11 11
     {
12
-        if ( $tenant) {
12
+        if ($tenant) {
13 13
             self::connection(Connections::Tenant);
14 14
         } else {
15 15
             self::connection('mysql');
Please login to merge, or discard this patch.
app/Http/Middleware/Multitenant.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
         \DB::purge('mysql');
24 24
         \DB::reconnect('mysql');
25 25
 
26
-        if (! $request->user()) {
26
+        if (!$request->user()) {
27 27
             return $next($request);
28 28
         }
29 29
 
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/RegisterController.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
 
45 45
     protected function create(array $data)
46 46
     {
47
-        try{
47
+        try {
48 48
             DB::beginTransaction();
49 49
             // create person
50 50
             $person = new Person();
@@ -53,15 +53,15 @@  discard block
 block discarded – undo
53 53
             $person->save();
54 54
 
55 55
             // get user_group_id
56
-            $user_group = UserGroup::where('name','Administrators')->first();
57
-            if($user_group == null) {
56
+            $user_group = UserGroup::where('name', 'Administrators')->first();
57
+            if ($user_group == null) {
58 58
                 // create user_group
59 59
                 $user_group = UserGroup::create(['name'=>'Administrators', 'description'=>'Administrator users group']);
60 60
             }
61 61
 
62 62
             // get role_id
63 63
             $role = Role::where('name', 'supervisor')->first();
64
-            if($role == null) {
64
+            if ($role == null) {
65 65
                 $role = Role::create(['menu_id'=>1, 'name'=>'supervisor', 'display_name'=>'Supervisor', 'description'=>'Supervisor role.']);
66 66
             }
67 67
             $user = User::create([
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
 
97 97
 
98 98
             return $user;
99
-        }catch(\Exception $e){
99
+        } catch (\Exception $e) {
100 100
             DB::rollBack();
101 101
             throw $e;
102 102
         }
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@
 block discarded – undo
96 96
 
97 97
 
98 98
             return $user;
99
-        }catch(\Exception $e){
99
+        } catch(\Exception $e){
100 100
             DB::rollBack();
101 101
             throw $e;
102 102
         }
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/LoginController.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
     {
56 56
         $user = $this->loggableUser($request);
57 57
 
58
-        if (! $user) {
58
+        if (!$user) {
59 59
             return false;
60 60
         }
61 61
 
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
         $user = User::whereEmail($request->input('email'))->first();
80 80
         $company = $user->company();
81 81
         $tanent = false;
82
-        if($company) {
82
+        if ($company) {
83 83
             $tanent = true;
84 84
         }
85 85
 
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
             // Tenant::set($company);
93 93
             $value = Connections::Tenant.$company->id;
94 94
 
95
-        }else{
95
+        } else {
96 96
             $value = '';
97 97
 
98 98
         }
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 
106 106
             \Session::put('db', $value);
107 107
 
108
-        if (! optional($user)->currentPasswordIs($request->input('password'))) {
108
+        if (!optional($user)->currentPasswordIs($request->input('password'))) {
109 109
             return;
110 110
         }
111 111
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -92,7 +92,7 @@
 block discarded – undo
92 92
             // Tenant::set($company);
93 93
             $value = Connections::Tenant.$company->id;
94 94
 
95
-        }else{
95
+        } else{
96 96
             $value = '';
97 97
 
98 98
         }
Please login to merge, or discard this patch.
app/Providers/AppServiceProvider.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -31,25 +31,25 @@
 block discarded – undo
31 31
 
32 32
     public function boot()
33 33
     {
34
-        $this->app->bind(ValidatePersonStore::class, function () {
34
+        $this->app->bind(ValidatePersonStore::class, function() {
35 35
             return new LocalPersonStore();
36 36
         });
37
-        $this->app->bind(ValidatePersonUpdate::class, function () {
37
+        $this->app->bind(ValidatePersonUpdate::class, function() {
38 38
             return new LocalPersonUpdate();
39 39
         });
40
-        $this->app->bind(ValidatePersonRequest::class, function () {
40
+        $this->app->bind(ValidatePersonRequest::class, function() {
41 41
             return new LocalPersonRequest();
42 42
         });
43
-        $this->app->bind(EnsoPerson::class, function () {
43
+        $this->app->bind(EnsoPerson::class, function() {
44 44
             return new LocalPerson();
45 45
         });
46
-        $this->app->bind(Person::class, function () {
46
+        $this->app->bind(Person::class, function() {
47 47
             return new LocalPerson();
48 48
         });
49
-        $this->app->bind(PersonTable::class, function () {
49
+        $this->app->bind(PersonTable::class, function() {
50 50
             return new LocalPersonTable();
51 51
         });
52
-        $this->app->bind(PersonForm::class, function () {
52
+        $this->app->bind(PersonForm::class, function() {
53 53
             return new LocalPersonForm();
54 54
         });
55 55
     }
Please login to merge, or discard this patch.
app/DynamicRelations/Company/Discussions.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,6 +15,6 @@
 block discarded – undo
15 15
 
16 16
     public function closure(): Closure
17 17
     {
18
-        return fn () => $this->morphMany(Discussion::class, 'discussable');
18
+        return fn() => $this->morphMany(Discussion::class, 'discussable');
19 19
     }
20 20
 }
Please login to merge, or discard this patch.
app/DynamicRelations/Company/Documents.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,6 +16,6 @@
 block discarded – undo
16 16
 
17 17
     public function closure(): Closure
18 18
     {
19
-        return fn () => $this->morphMany(Document::class, 'documentable');
19
+        return fn() => $this->morphMany(Document::class, 'documentable');
20 20
     }
21 21
 }
Please login to merge, or discard this patch.