Passed
Push — chore/format-php ( 5ef121 )
by Grant
16:21
created
app/Services/Validation/Rules/CourseValidator.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -28,11 +28,11 @@
 block discarded – undo
28 28
         // Validate basic data is filled in
29 29
         Validator::make($courseValidator->getAttributes(), [
30 30
             'applicant_id' => [
31
-             'required',
31
+                'required',
32 32
                 Rule::in($applicant_ids->toArray()),
33 33
             ],
34
-             'course_status_id' => [
35
-             'required',
34
+                'course_status_id' => [
35
+                'required',
36 36
                 Rule::in($this->course_status_ids->toArray()),
37 37
             ]
38 38
          
Please login to merge, or discard this patch.
app/Services/Validation/Rules/DegreeValidator.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,11 +28,11 @@
 block discarded – undo
28 28
         Validator::make($degreeValidator->getAttributes(), [
29 29
             'applicant_id' => [
30 30
             'required',
31
-               Rule::in($applicant_ids->toArray()),
31
+                Rule::in($applicant_ids->toArray()),
32 32
             ],
33 33
             'degree_type_id' => [
34 34
             'required',
35
-               Rule::in($this->degree_type_id->toArray()),
35
+                Rule::in($this->degree_type_id->toArray()),
36 36
             ]
37 37
 
38 38
         ])->validate();
Please login to merge, or discard this patch.
app/Services/Validation/Rules/WorkSamplesValidator.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -26,11 +26,11 @@
 block discarded – undo
26 26
         Validator::make($workSamplesValidator->getAttributes(), [
27 27
             'applicant_id' => [
28 28
             'required',
29
-               Rule::in($applicant_ids->toArray()),
29
+                Rule::in($applicant_ids->toArray()),
30 30
             ],
31 31
             'file_type_id' => [
32 32
             'required',
33
-               Rule::in($this->file_type_id->toArray()),
33
+                Rule::in($this->file_type_id->toArray()),
34 34
             ]
35 35
        
36 36
         ])->validate();
Please login to merge, or discard this patch.
app/Services/Validation/ApplicationValidator.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
     protected function addNestedValidatorRules($nestedAttribute, $validatorRules, $rules = [])
82 82
     {
83 83
         // prepend the attribute name of each validator rule with the nested attribute name
84
-        $newRules = $this->arrayMapKeys(function ($key) use ($nestedAttribute) {
84
+        $newRules = $this->arrayMapKeys(function($key) use ($nestedAttribute) {
85 85
                 return implode('.', [$nestedAttribute, $key]);
86 86
         },
87 87
             $validatorRules);
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
     protected function addNestedValidatorRules($nestedAttribute, $validatorRules, $rules = [])
82 82
     {
83 83
         // prepend the attribute name of each validator rule with the nested attribute name
84
-        $newRules = $this->arrayMapKeys(function ($key) use ($nestedAttribute) {
84
+        $newRules = $this->arrayMapKeys(function ($key) use ($nestedAttribute){
85 85
                 return implode('.', [$nestedAttribute, $key]);
86 86
         },
87 87
             $validatorRules);
Please login to merge, or discard this patch.
app/Http/Controllers/Api/CriteriaController.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -12,11 +12,11 @@
 block discarded – undo
12 12
 class CriteriaController extends Controller
13 13
 {
14 14
 /**
15
-     * Converts a Criteria to the shape sent and recieved by the api.
16
-     *
17
-     * @param Criteria $model
18
-     * @return void
19
-     */
15
+ * Converts a Criteria to the shape sent and recieved by the api.
16
+ *
17
+ * @param Criteria $model
18
+ * @return void
19
+ */
20 20
     public function toApiArray(Criteria $model)
21 21
     {
22 22
         return array_merge($model->toArray(), $model->getTranslationsArray());
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
      */
31 31
     public function indexByJob(JobPoster $jobPoster)
32 32
     {
33
-        $toApiArray = array($this, 'toApiArray');
33
+        $toApiArray = array ($this, 'toApiArray');
34 34
         $criteriaAray = Criteria::where('job_poster_id', $jobPoster->id)->get()->map($toApiArray);
35 35
         return response()->json($criteriaAray);
36 36
     }
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
      */
45 45
     public function batchUpdate(Request $request, JobPoster $jobPoster)
46 46
     {
47
-        $toApiArray = array($this, 'toApiArray');
47
+        $toApiArray = array ($this, 'toApiArray');
48 48
 
49 49
         $newCriteria = collect($request->input()); // TODO: switch to validated
50 50
         $oldCriteria = $jobPoster->criteria;
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
             }
63 63
         }
64 64
 
65
-        $isUnsaved = function ($criteria, $savedIds): bool {
65
+        $isUnsaved = function($criteria, $savedIds): bool {
66 66
             return !array_key_exists('id', $criteria) || !in_array($criteria['id'], $savedIds);
67 67
         };
68 68
 
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
         $newSkillId = null,
164 164
         $newSkillLevelId = null,
165 165
         $newCriteriaTypeId = null
166
-    ) {
166
+    ){
167 167
         $notification = new AssessmentPlanNotification();
168 168
         $notification->job_poster_id = $criteria->job_poster_id;
169 169
         $notification->type = $type;
Please login to merge, or discard this patch.