Passed
Push — feature/hr-portal ( ae4ab3...ab04c7 )
by Chris
12:13 queued 11s
created
app/Http/Requests/DepartmentCrudRequest.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
     public function authorize() : bool
15 15
     {
16 16
         // Only allow updates if the user is a logged in Admin.
17
-        return backpack_auth()->check();
17
+        return backpack_auth ()->check ();
18 18
     }
19 19
 
20 20
     /**
Please login to merge, or discard this patch.
app/Http/Requests/UpdateManagerProfileRequest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
                 'email',
59 59
                 // Email may match existing email for this user,
60 60
                 // but must be unique if changed.
61
-                Rule::unique('users', 'email')->ignore($this->manager->user->id)
61
+                Rule::unique ('users', 'email')->ignore ($this->manager->user->id)
62 62
             ],
63 63
             'gov_email' => [
64 64
                 'nullable',
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
                 'confirmed'
80 80
             ],
81 81
 
82
-            'department_id' => ['required', new ValidIdRule(Department::class)],
82
+            'department_id' => ['required', new ValidIdRule (Department::class)],
83 83
 
84 84
             'years_experience' => 'nullable|numeric|min:0',
85 85
             'gc_directory_url' => 'nullable|url',
Please login to merge, or discard this patch.
app/Http/Requests/UpdateRatingGuideAnswer.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -19,8 +19,8 @@  discard block
 block discarded – undo
19 19
         //$answer = RatingGuideAnswer::find($this->route()->originalParameter('ratingGuideAnswer'));
20 20
 
21 21
         // The id parameter in the route is typehinted to magically become a RatingGuideAnswer object.
22
-        $answer = $this->route('ratingGuideAnswer');
23
-        return $answer && $this->user()->can('update', $answer);
22
+        $answer = $this->route ('ratingGuideAnswer');
23
+        return $answer && $this->user ()->can ('update', $answer);
24 24
     }
25 25
 
26 26
     /**
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
         return [
34 34
             // RatingGuideQUestionId shouldn't be updated after creation
35 35
             //'rating_guide_question_id' => ['required', new RatingGuideQuestionRule()],
36
-            'criterion_id' => ['nullable', new ValidIdRule(Criteria::class)],
36
+            'criterion_id' => ['nullable', new ValidIdRule (Criteria::class)],
37 37
             'expected_answer' => 'nullable|string',
38 38
         ];
39 39
     }
Please login to merge, or discard this patch.
app/Http/Requests/SkillCrudRequest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
14 14
     public function authorize() : bool
15 15
     {
16 16
         // Only allow updates if the user is a logged in Admin.
17
-        return backpack_auth()->check();
17
+        return backpack_auth ()->check ();
18 18
     }
19 19
 
20 20
     /**
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     public function rules() : array
26 26
     {
27 27
         return [
28
-            'name' => 'required|unique_translation:skills,name' . (isset($this->id) ? ",{$this->id}" : ''),
28
+            'name' => 'required|unique_translation:skills,name'.(isset($this->id) ? ",{$this->id}" : ''),
29 29
             'description' => 'required',
30 30
             'skill_type_id' => 'exists:skill_types,id'
31 31
         ];
Please login to merge, or discard this patch.
app/Http/Requests/StoreJobPoster.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,6 +14,6 @@
 block discarded – undo
14 14
     public function authorize(): bool
15 15
     {
16 16
         // The STORE job poster method requires the user's manager id.
17
-        return $this->user()->manager !== null;
17
+        return $this->user ()->manager !== null;
18 18
     }
19 19
 }
Please login to merge, or discard this patch.
app/Http/Requests/UpdateManagerApi.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,9 +28,9 @@
 block discarded – undo
28 28
      */
29 29
     public function rules()
30 30
     {
31
-        $frequencyRule = new ValidIdRule(Frequency::class);
31
+        $frequencyRule = new ValidIdRule (Frequency::class);
32 32
         return [
33
-            'department_id' => ['nullable', new ValidIdRule(Department::class)],
33
+            'department_id' => ['nullable', new ValidIdRule (Department::class)],
34 34
             'gov_email' => [
35 35
                 'nullable',
36 36
                 'string',
Please login to merge, or discard this patch.
app/Http/Middleware/DateLocale.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -16,8 +16,8 @@
 block discarded – undo
16 16
      */
17 17
     public function handle($request, Closure $next)
18 18
     {
19
-        Date::setLocale(app()->getLocale());
19
+        Date::setLocale (app ()->getLocale ());
20 20
         
21
-        return $next($request);
21
+        return $next ($request);
22 22
     }
23 23
 }
Please login to merge, or discard this patch.
app/Http/Middleware/FinishManagerRegistration.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -14,13 +14,13 @@
 block discarded – undo
14 14
      */
15 15
     public function handle($request, Closure $next)
16 16
     {
17
-        $user = $request->user();
17
+        $user = $request->user ();
18 18
 
19
-        if ($user !== null && $user->isManager() && !$user->isGovIdentityConfirmed()) {
20
-            $request->session()->put('url.expected', $request->url());
21
-            return redirect(route('manager.first_visit'));
19
+        if ($user !== null && $user->isManager () && !$user->isGovIdentityConfirmed ()) {
20
+            $request->session ()->put ('url.expected', $request->url ());
21
+            return redirect (route ('manager.first_visit'));
22 22
         }
23 23
 
24
-        return $next($request);
24
+        return $next ($request);
25 25
     }
26 26
 }
Please login to merge, or discard this patch.
app/Http/Middleware/CheckIfAdmin.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
      */
23 23
     private function checkIfUserIsAdmin($user)
24 24
     {
25
-        return ($user->isAdmin());
25
+        return ($user->isAdmin ());
26 26
     }
27 27
 
28 28
     /**
@@ -34,10 +34,10 @@  discard block
 block discarded – undo
34 34
      */
35 35
     private function respondToUnauthorizedRequest($request)
36 36
     {
37
-        if ($request->ajax() || $request->wantsJson()) {
38
-            return response(trans('backpack::base.unauthorized'), 401);
37
+        if ($request->ajax () || $request->wantsJson ()) {
38
+            return response (trans ('backpack::base.unauthorized'), 401);
39 39
         } else {
40
-            return redirect()->guest(backpack_url('login'));
40
+            return redirect ()->guest (backpack_url ('login'));
41 41
         }
42 42
     }
43 43
 
@@ -51,14 +51,14 @@  discard block
 block discarded – undo
51 51
      */
52 52
     public function handle($request, Closure $next)
53 53
     {
54
-        if (backpack_auth()->guest()) {
55
-            return $this->respondToUnauthorizedRequest($request);
54
+        if (backpack_auth ()->guest ()) {
55
+            return $this->respondToUnauthorizedRequest ($request);
56 56
         }
57 57
 
58
-        if (!$this->checkIfUserIsAdmin(backpack_user())) {
59
-            return $this->respondToUnauthorizedRequest($request);
58
+        if (!$this->checkIfUserIsAdmin (backpack_user ())) {
59
+            return $this->respondToUnauthorizedRequest ($request);
60 60
         }
61 61
 
62
-        return $next($request);
62
+        return $next ($request);
63 63
     }
64 64
 }
Please login to merge, or discard this patch.