@@ -18,7 +18,7 @@ |
||
18 | 18 | */ |
19 | 19 | public function up() |
20 | 20 | { |
21 | - Schema::create('paypal_accounts', function (Blueprint $table) { |
|
21 | + Schema::create('paypal_accounts', function(Blueprint $table) { |
|
22 | 22 | $table->increments('id'); |
23 | 23 | |
24 | 24 | $table->string('some_id'); |
@@ -11,7 +11,7 @@ |
||
11 | 11 | */ |
12 | 12 | public function up() |
13 | 13 | { |
14 | - Schema::create('settings', function (Blueprint $table) { |
|
14 | + Schema::create('settings', function(Blueprint $table) { |
|
15 | 15 | $table->increments('id'); |
16 | 16 | $table->string('key')->unique(); |
17 | 17 | $table->string('value'); |
@@ -65,7 +65,7 @@ |
||
65 | 65 | */ |
66 | 66 | public function run($email, $userId = null) |
67 | 67 | { |
68 | - if(!$userId){ |
|
68 | + if (!$userId) { |
|
69 | 69 | $userId = $this->getAuthenticatedUserTask->run()->id; |
70 | 70 | } |
71 | 71 |
@@ -18,7 +18,7 @@ |
||
18 | 18 | */ |
19 | 19 | public function up() |
20 | 20 | { |
21 | - Schema::create('applications', function (Blueprint $table) { |
|
21 | + Schema::create('applications', function(Blueprint $table) { |
|
22 | 22 | $table->increments('id'); |
23 | 23 | |
24 | 24 | $table->string('name'); |
@@ -4,7 +4,7 @@ |
||
4 | 4 | use App\Containers\Application\Models\Application; |
5 | 5 | use App\Containers\User\Models\User; |
6 | 6 | |
7 | -$factory->define(Application::class, function (Faker\Generator $faker) { |
|
7 | +$factory->define(Application::class, function(Faker\Generator $faker) { |
|
8 | 8 | |
9 | 9 | return [ |
10 | 10 | 'name' => $faker->name, |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | |
94 | 94 | $token = str_replace('Bearer ', '', $request->header('authorization')); |
95 | 95 | |
96 | - if(!$token){ |
|
96 | + if (!$token) { |
|
97 | 97 | throw new AuthenticationFailedException('Empty Token!'); |
98 | 98 | } |
99 | 99 | |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | throw new UserNotPermittedException(); |
114 | 114 | } |
115 | 115 | |
116 | - }else{ |
|
116 | + } else { |
|
117 | 117 | return (App::make(\Dingo\Api\Http\Middleware\Auth::class))->handle($request, $next); |
118 | 118 | // another way to do handle this is by calling `$user = $this->jwtAuthAdapter->toUser($token);` |
119 | 119 | // and continuing the execution of this code till the last return, but to maintain consistency |