Test Setup Failed
Branch master (86f4a4)
by Shawn
04:57
created
app/Http/ViewComposers/ActionItemsComposer.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
 
104 104
 
105 105
     /**
106
-     * @param $calculatedDays
106
+     * @param integer $calculatedDays
107 107
      * @param $user
108 108
      * @param $builtUser
109 109
      */
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -33,13 +33,13 @@  discard block
 block discarded – undo
33 33
     private function getDueTraining()
34 34
     {
35 35
 
36
-        return Training::with(['users', 'assignedUsers' => function ($query) {
36
+        return Training::with(['users', 'assignedUsers' => function($query) {
37 37
             //filter the assignedusers we get back
38 38
             $query->ActiveUsers()
39 39
                 ->whereNull('completed_date')
40 40
                 ->where('due_date', '<=', Carbon::now());
41 41
             }])
42
-            ->whereHas('assignedUsers', function ($q) {
42
+            ->whereHas('assignedUsers', function($q) {
43 43
                 //filter the training we get.
44 44
                 $q->ActiveUsers()
45 45
                     ->whereNull('completed_date')
@@ -53,9 +53,9 @@  discard block
 block discarded – undo
53 53
      */
54 54
     private function getExpiringVisits()
55 55
     {
56
-        return User::with(['visits' => function ($query) {
56
+        return User::with(['visits' => function($query) {
57 57
             $query->whereBetween('expiration_date', [Carbon::now(), Carbon::now()->addWeek()]);
58
-        }])->whereHas('visits', function ($q) {
58
+        }])->whereHas('visits', function($q) {
59 59
             $q->whereBetween('expiration_date', [Carbon::now(), Carbon::now()->addWeek()]);
60 60
         })->Active()->get();
61 61
     }
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
             $years = 5;
91 91
         } else if ($user->access_level == 'S' || $user->clearance == 'S') {
92 92
             $years = 10;
93
-        } else if($user->clearance = 'TS') {
93
+        } else if ($user->clearance = 'TS') {
94 94
             $years = 5;
95 95
         }
96 96
 
Please login to merge, or discard this patch.
app/Mail/SendNewsEmail.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
     /**
17 17
      * Create a new message instance.
18 18
      *
19
-     * @return void
19
+     * @return Mailable
20 20
      */
21 21
     public function __construct(News $news)
22 22
     {
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
     /**
27 27
      * Build the message.
28 28
      *
29
-     * @return Illuminate\Mail\Mailable
29
+     * @return SendNewsEmail
30 30
      */
31 31
     public function build()
32 32
     {
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     public function __construct(News $news)
22 22
     {
23
-       $this->news = $news;
23
+        $this->news = $news;
24 24
     }
25 25
 
26 26
     /**
Please login to merge, or discard this patch.
app/Providers/AppServiceProvider.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
 
61 61
     /**
62 62
      * @param $user
63
-     * @param $ignoreList
63
+     * @param string[] $ignoreList
64 64
      * @param $log
65 65
      */
66 66
     private function buildLogComment($user, $ignoreList, $log)
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
     public function boot()
18 18
     {
19 19
         // If the save() function is used on the User model, we will generate a new log note.
20
-        User::updating(function ($user) {
20
+        User::updating(function($user) {
21 21
             $this->createUserLog($user);
22 22
         });
23 23
     }
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 
52 52
             $log['author_id'] = Auth::user() ? Auth::user()->id : 1;
53 53
             $log['user_id'] = $user->id;
54
-            if( !empty($log['comment']) ) {
54
+            if (!empty($log['comment'])) {
55 55
                 Log::create($log);
56 56
             }
57 57
         }
Please login to merge, or discard this patch.
app/TrainingUser.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
      */
50 50
     public function scopeActiveUsers($query)
51 51
     {
52
-        return $query->whereHas('user', function ($q) {
52
+        return $query->whereHas('user', function($q) {
53 53
             $q->where('status', 'active');
54 54
         });
55 55
     }
Please login to merge, or discard this patch.
app/Listeners/ResolveLdap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
      */
28 28
     public function handle()
29 29
     {
30
-        if(config('auth.guards.web.provider') == 'adldap') {
30
+        if (config('auth.guards.web.provider') == 'adldap') {
31 31
             $this->addMissingUsers();
32 32
         }
33 33
     }
Please login to merge, or discard this patch.
app/Listeners/EmailTraining.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@
 block discarded – undo
59 59
         Mail::send(
60 60
             'emails.training',
61 61
             ['user' => $user, 'training' => $training, 'due_date' => $dueDate, 'trainingUser' => $trainingUser],
62
-            function ($m) use ($user, $training) {
62
+            function($m) use ($user, $training) {
63 63
                 $m->to($user->email, $user->userFullName)->subject($training->name . " was assigned to you.");
64 64
 
65 65
                 //ATTACH FILES
Please login to merge, or discard this patch.
app/User.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
     /**
35 35
      * @var array
36 36
      */
37
-    protected $hidden = array('username','password');
37
+    protected $hidden = array('username', 'password');
38 38
 
39 39
     public function supervisor()
40 40
     {
Please login to merge, or discard this patch.
app/Handlers/Duty/DutyGroups.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -115,11 +115,11 @@
 block discarded – undo
115 115
     {
116 116
         $row = '';
117 117
         foreach ($entry['group'] as $user) {
118
-			if(Gate::allows('view')) {
119
-				$row .= "<a href='" . url('user', $user->id) . "'>" . $user->userFullName . "</a> & ";
120
-			} else {
121
-				$row .= $user->userFullName . " & ";
122
-			}
118
+            if(Gate::allows('view')) {
119
+                $row .= "<a href='" . url('user', $user->id) . "'>" . $user->userFullName . "</a> & ";
120
+            } else {
121
+                $row .= $user->userFullName . " & ";
122
+            }
123 123
         }
124 124
         $row = rtrim($row, '& ');
125 125
         return $row;
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
 
14 14
     public function __construct(Duty $duty)
15 15
     {
16
-        parent::__construct($duty);;
16
+        parent::__construct($duty); ;
17 17
     }
18 18
 
19 19
     public function HTMLOutput()
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 
37 37
     public function emailOutput()
38 38
     {
39
-        $collection = $this->list->map(function ($value, $key) {
39
+        $collection = $this->list->map(function($value, $key) {
40 40
             return [
41 41
                 'users' => $value['group'],
42 42
                 'date' => $value['date']
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
         $newList = new Collection();
72 72
         $count = $this->list->count();
73 73
 
74
-        for ($i = 0; $i < $count ; $i++)
74
+        for ($i = 0; $i < $count; $i++)
75 75
         {
76 76
             $newList->push([
77 77
                 'date' => $dates[$i],
@@ -92,9 +92,9 @@  discard block
 block discarded – undo
92 92
             ->orderBy('date', 'ASC')
93 93
             ->get();
94 94
 
95
-        foreach($dutySwaps as $swap)
95
+        foreach ($dutySwaps as $swap)
96 96
         {
97
-            foreach($this->list as $key => $entry)
97
+            foreach ($this->list as $key => $entry)
98 98
             {
99 99
                 if ($swap->date == $entry['date']) {
100 100
                     $this->list[$key] = [
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
     {
116 116
         $row = '';
117 117
         foreach ($entry['group'] as $user) {
118
-			if(Gate::allows('view')) {
118
+			if (Gate::allows('view')) {
119 119
 				$row .= "<a href='" . url('user', $user->id) . "'>" . $user->userFullName . "</a> & ";
120 120
 			} else {
121 121
 				$row .= $user->userFullName . " & ";
Please login to merge, or discard this patch.
app/Handlers/Duty/DutyDates.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -40,9 +40,9 @@  discard block
 block discarded – undo
40 40
     {
41 41
         if ($cycle == 'monthly') {
42 42
             return Carbon::now()->startOfMonth();
43
-        }else if($cycle == 'weekly') {
43
+        } else if ($cycle == 'weekly') {
44 44
             return Carbon::now()->startOfWeek();
45
-        }else if($cycle == 'daily') {
45
+        } else if ($cycle == 'daily') {
46 46
             return Carbon::now()->startOfDay();
47 47
         } else {
48 48
             Log::error('Duty has an invalid cycle name. Must use monthly, weekly or daily');
@@ -54,9 +54,9 @@  discard block
 block discarded – undo
54 54
     {
55 55
         if ($cycle == 'monthly') {
56 56
             return $date->addMonth();
57
-        }else if($cycle == 'weekly') {
57
+        } else if ($cycle == 'weekly') {
58 58
             return $date->addWeek();
59
-        }else if($cycle == 'daily') {
59
+        } else if ($cycle == 'daily') {
60 60
             return $date->addDay();
61 61
         } else {
62 62
             Log::error('Duty has an invalid cycle name. Must use monthly, weekly or daily');
Please login to merge, or discard this patch.
Braces   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -40,9 +40,9 @@  discard block
 block discarded – undo
40 40
     {
41 41
         if ($cycle == 'monthly') {
42 42
             return Carbon::now()->startOfMonth();
43
-        }else if($cycle == 'weekly') {
43
+        } else if($cycle == 'weekly') {
44 44
             return Carbon::now()->startOfWeek();
45
-        }else if($cycle == 'daily') {
45
+        } else if($cycle == 'daily') {
46 46
             return Carbon::now()->startOfDay();
47 47
         } else {
48 48
             Log::error('Duty has an invalid cycle name. Must use monthly, weekly or daily');
@@ -54,9 +54,9 @@  discard block
 block discarded – undo
54 54
     {
55 55
         if ($cycle == 'monthly') {
56 56
             return $date->addMonth();
57
-        }else if($cycle == 'weekly') {
57
+        } else if($cycle == 'weekly') {
58 58
             return $date->addWeek();
59
-        }else if($cycle == 'daily') {
59
+        } else if($cycle == 'daily') {
60 60
             return $date->addDay();
61 61
         } else {
62 62
             Log::error('Duty has an invalid cycle name. Must use monthly, weekly or daily');
Please login to merge, or discard this patch.