@@ -17,7 +17,7 @@ |
||
| 17 | 17 | */ |
| 18 | 18 | public function handle($request, Closure $next, $guard = null) |
| 19 | 19 | { |
| 20 | - if (! auth()->user()->verified) { |
|
| 20 | + if ( ! auth()->user()->verified) { |
|
| 21 | 21 | return response(view('auth.unconfirmed'), 403); |
| 22 | 22 | } |
| 23 | 23 | |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | */ |
| 20 | 20 | public function handle($request, Closure $next) |
| 21 | 21 | { |
| 22 | - if (! auth()->check() || ! auth()->user()->isStudent()) { |
|
| 22 | + if ( ! auth()->check() || ! auth()->user()->isStudent()) { |
|
| 23 | 23 | throw new AuthorizationException('Unauthorized.'); |
| 24 | 24 | } |
| 25 | 25 | |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | */ |
| 20 | 20 | public function handle($request, Closure $next) |
| 21 | 21 | { |
| 22 | - if (! auth()->check() || ! auth()->user()->isAdmin()) { |
|
| 22 | + if ( ! auth()->check() || ! auth()->user()->isAdmin()) { |
|
| 23 | 23 | throw new AuthorizationException('Unauthorized.'); |
| 24 | 24 | } |
| 25 | 25 | |
@@ -16,7 +16,7 @@ |
||
| 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('home'); |
@@ -16,7 +16,7 @@ |
||
| 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('home'); |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | public function create($enrollmentId) |
| 35 | 35 | { |
| 36 | 36 | try { |
| 37 | - $data = DB::transaction(function () use ($enrollmentId) { |
|
| 37 | + $data = DB::transaction(function() use ($enrollmentId) { |
|
| 38 | 38 | $enrollment = Enrollment::findOrFail($enrollmentId); |
| 39 | 39 | $this->authorize('exchange', $enrollment); |
| 40 | 40 | |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | return compact('enrollment', 'matchingEnrollments'); |
| 50 | 50 | }); |
| 51 | 51 | |
| 52 | - $data['matchingEnrollments'] = $data['matchingEnrollments']->map(function ($item) { |
|
| 52 | + $data['matchingEnrollments'] = $data['matchingEnrollments']->map(function($item) { |
|
| 53 | 53 | $newItem = []; |
| 54 | 54 | $newItem['id'] = $item->id; |
| 55 | 55 | $newItem['_toString'] = $item->present()->inlineToString(); |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | public function store(CreateRequest $request) |
| 76 | 76 | { |
| 77 | 77 | try { |
| 78 | - DB::transaction(function () use ($request) { |
|
| 78 | + DB::transaction(function() use ($request) { |
|
| 79 | 79 | $this->validate($request, [ |
| 80 | 80 | 'from_enrollment_id' => 'exists:enrollments,id', |
| 81 | 81 | 'to_enrollment_id' => 'exists:enrollments,id', |
@@ -89,7 +89,7 @@ discard block |
||
| 89 | 89 | // already exists. If the inverse record is found then we will |
| 90 | 90 | // exchange and update both enrollments of this exchange. |
| 91 | 91 | $exchange = Exchange::findMatchingExchange($fromEnrollment, $toEnrollment); |
| 92 | - if (! is_null($exchange)) { |
|
| 92 | + if ( ! is_null($exchange)) { |
|
| 93 | 93 | return $exchange->perform(); |
| 94 | 94 | } |
| 95 | 95 | |
@@ -122,7 +122,7 @@ discard block |
||
| 122 | 122 | */ |
| 123 | 123 | public function storeConfirmation(Request $request) |
| 124 | 124 | { |
| 125 | - $exchange = DB::transaction(function () use ($request) { |
|
| 125 | + $exchange = DB::transaction(function() use ($request) { |
|
| 126 | 126 | $this->validate($request, [ |
| 127 | 127 | 'exchange_id' => 'exists:exchanges,id', |
| 128 | 128 | ]); |
@@ -149,7 +149,7 @@ discard block |
||
| 149 | 149 | */ |
| 150 | 150 | public function storeDecline(Request $request) |
| 151 | 151 | { |
| 152 | - $exchange = DB::transaction(function () use ($request) { |
|
| 152 | + $exchange = DB::transaction(function() use ($request) { |
|
| 153 | 153 | $this->validate($request, [ |
| 154 | 154 | 'exchange_id' => 'exists:exchanges,id', |
| 155 | 155 | ]); |
@@ -178,7 +178,7 @@ discard block |
||
| 178 | 178 | */ |
| 179 | 179 | public function destroy(Request $request) |
| 180 | 180 | { |
| 181 | - DB::transaction(function () use ($request) { |
|
| 181 | + DB::transaction(function() use ($request) { |
|
| 182 | 182 | $this->validate($request, [ |
| 183 | 183 | 'exchange_id' => 'exists:exchanges,id', |
| 184 | 184 | ]); |