Passed
Push — develop ( 44c5b3...446e7b )
by Francisco
04:50 queued 14s
created
app/Http/Controllers/CourseController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,11 +14,11 @@
 block discarded – undo
14 14
      */
15 15
     public function index()
16 16
     {
17
-        $courses = DB::transaction(function () {
17
+        $courses = DB::transaction(function() {
18 18
             return Course::orderedList()->get();
19 19
         });
20 20
 
21
-        $courses = $courses->groupBy(function ($course) {
21
+        $courses = $courses->groupBy(function($course) {
22 22
             return $course->present()->getOrdinalYear();
23 23
         });
24 24
 
Please login to merge, or discard this patch.
app/Providers/ComposerServiceProvider.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
      */
15 15
     public function boot()
16 16
     {
17
-        View::composer('*', function ($view) {
17
+        View::composer('*', function($view) {
18 18
             $view->with('settings', app('settings'));
19 19
         });
20 20
     }
Please login to merge, or discard this patch.
app/Http/Middleware/AuthorizeStudent.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     public function handle($request, Closure $next)
21 21
     {
22
-        if (! Auth::user()->isStudent()) {
22
+        if ( ! Auth::user()->isStudent()) {
23 23
             abort(404);
24 24
         }
25 25
 
Please login to merge, or discard this patch.
app/Http/Middleware/AuthorizeAdministrator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     public function handle($request, Closure $next)
21 21
     {
22
-        if (! Auth::user()->isAdmin()) {
22
+        if ( ! Auth::user()->isAdmin()) {
23 23
             abort(404);
24 24
         }
25 25
 
Please login to merge, or discard this patch.
app/Http/Middleware/AuthorizeEnrollmentActions.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
      */
17 17
     public function handle($request, Closure $next)
18 18
     {
19
-        if (! app('settings')->withinEnrollmentPeriod()) {
19
+        if ( ! app('settings')->withinEnrollmentPeriod()) {
20 20
             flash('The enrollments period is closed. You are not allowed to perform this action.')->error();
21 21
 
22 22
             return redirect()->route('dashboard');
Please login to merge, or discard this patch.
app/Http/Middleware/AuthorizeExchangeActions.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
      */
17 17
     public function handle($request, Closure $next)
18 18
     {
19
-        if (! app('settings')->withinExchangePeriod()) {
19
+        if ( ! app('settings')->withinExchangePeriod()) {
20 20
             flash('The exchanges period is closed. You are not allowed to perform this action.')->error();
21 21
 
22 22
             return redirect()->route('dashboard');
Please login to merge, or discard this patch.
app/Http/Controllers/EnrollmentExchangeController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -34,10 +34,10 @@  discard block
 block discarded – undo
34 34
     public function create($id)
35 35
     {
36 36
         try {
37
-            $data = DB::transaction(function () use ($id) {
37
+            $data = DB::transaction(function() use ($id) {
38 38
                 $enrollment = Auth::student()->enrollments()->findOrFail($id);
39 39
 
40
-                if (! $enrollment->availableForExchange()) {
40
+                if ( ! $enrollment->availableForExchange()) {
41 41
                     throw new \LogicException('The enrollment is not available for exchange.');
42 42
                 }
43 43
 
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
                 return compact('enrollment', 'matchingEnrollments');
49 49
             });
50 50
 
51
-            $data['matchingEnrollments'] = $data['matchingEnrollments']->map(function ($item) {
51
+            $data['matchingEnrollments'] = $data['matchingEnrollments']->map(function($item) {
52 52
                 return [
53 53
                     'id' => $item->id,
54 54
                     '_toString' => $item->present()->inlineToString(),
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
     public function store($id, CreateRequest $request)
75 75
     {
76 76
         try {
77
-            $exchange = DB::transaction(function () use ($id, $request) {
77
+            $exchange = DB::transaction(function() use ($id, $request) {
78 78
                 $this->validate($request, [
79 79
                     'to_enrollment_id' => 'exists:enrollments,id',
80 80
                 ]);
Please login to merge, or discard this patch.
app/Http/Controllers/ExchangeController.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
      */
32 32
     public function confirm($id)
33 33
     {
34
-        $exchange = DB::transaction(function () use ($id) {
34
+        $exchange = DB::transaction(function() use ($id) {
35 35
             $exchange = Auth::student()->proposedExchanges()->findOrFail($id);
36 36
 
37 37
             return $exchange->perform();
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
      */
52 52
     public function decline($id)
53 53
     {
54
-        $exchange = DB::transaction(function () use ($id) {
54
+        $exchange = DB::transaction(function() use ($id) {
55 55
             $exchange = Auth::student()->proposedExchanges()->findOrFail($id);
56 56
             $exchange->delete();
57 57
 
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
      */
73 73
     public function destroy($id)
74 74
     {
75
-        DB::transaction(function () use ($id) {
75
+        DB::transaction(function() use ($id) {
76 76
             Auth::student()->requestedExchanges()->findOrFail($id)->delete();
77 77
         });
78 78
         flash('The shift exchange request was successfully deleted.')->success();
Please login to merge, or discard this patch.
app/Http/Controllers/DashboardController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -35,13 +35,13 @@  discard block
 block discarded – undo
35 35
      */
36 36
     protected function adminDashboard()
37 37
     {
38
-        $courses = DB::transaction(function () {
38
+        $courses = DB::transaction(function() {
39 39
             return Course::withCount('enrollments')
40 40
                 ->orderedList()
41 41
                 ->get();
42 42
         });
43 43
 
44
-        $courses = $courses->groupBy(function ($course) {
44
+        $courses = $courses->groupBy(function($course) {
45 45
             return $course->present()->getOrdinalYear();
46 46
         });
47 47
 
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
      */
56 56
     protected function studentDashboard()
57 57
     {
58
-        $data = DB::transaction(function () {
58
+        $data = DB::transaction(function() {
59 59
             $proposedExchanges = Auth::student()->proposedExchanges()->get();
60 60
             $requestedExchanges = Auth::student()->requestedExchanges()->get();
61 61
             $enrollments = Auth::student()->enrollments()
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
             return compact('proposedExchanges', 'requestedExchanges', 'enrollments');
67 67
         });
68 68
 
69
-        $data['enrollments'] = $data['enrollments']->groupBy(function ($enrollment) {
69
+        $data['enrollments'] = $data['enrollments']->groupBy(function($enrollment) {
70 70
             return $enrollment->course->present()->getOrdinalYear();
71 71
         });
72 72
 
Please login to merge, or discard this patch.