@@ -11,7 +11,7 @@ |
||
| 11 | 11 | */ |
| 12 | 12 | public function up() |
| 13 | 13 | { |
| 14 | - Schema::create('users', function (Blueprint $table) { |
|
| 14 | + Schema::create('users', function(Blueprint $table) { |
|
| 15 | 15 | $table->increments('id'); |
| 16 | 16 | $table->string('name'); |
| 17 | 17 | |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | */ |
| 12 | 12 | public function up() |
| 13 | 13 | { |
| 14 | - Schema::create('password_resets', function (Blueprint $table) { |
|
| 14 | + Schema::create('password_resets', function(Blueprint $table) { |
|
| 15 | 15 | $table->string('email')->index(); |
| 16 | 16 | $table->string('token')->index(); |
| 17 | 17 | $table->timestamp('created_at'); |
@@ -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'); |
@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | // User |
| 4 | -$factory->define(App\Containers\User\Models\User::class, function (Faker\Generator $faker) { |
|
| 4 | +$factory->define(App\Containers\User\Models\User::class, function(Faker\Generator $faker) { |
|
| 5 | 5 | return [ |
| 6 | 6 | 'name' => $faker->name, |
| 7 | 7 | 'email' => $faker->email, |
@@ -27,7 +27,7 @@ |
||
| 27 | 27 | * @param $email |
| 28 | 28 | * @param $password |
| 29 | 29 | * |
| 30 | - * @return mixed |
|
| 30 | + * @return string |
|
| 31 | 31 | */ |
| 32 | 32 | public function run(User $user) |
| 33 | 33 | { |
@@ -16,7 +16,7 @@ |
||
| 16 | 16 | |
| 17 | 17 | /** |
| 18 | 18 | * @param \App\Containers\User\Models\User $user |
| 19 | - * @param $confirmationUrl |
|
| 19 | + * @param string $confirmationUrl |
|
| 20 | 20 | */ |
| 21 | 21 | public function run(User $user, $confirmationUrl) |
| 22 | 22 | { |
@@ -23,7 +23,7 @@ |
||
| 23 | 23 | |
| 24 | 24 | /** |
| 25 | 25 | * @param \App\Containers\User\Models\User $user |
| 26 | - * @param $amount |
|
| 26 | + * @param integer $amount |
|
| 27 | 27 | * @param string $currency |
| 28 | 28 | * |
| 29 | 29 | * @return mixed |
@@ -5,7 +5,6 @@ |
||
| 5 | 5 | use App\Containers\Payments\Contracts\Chargeable; |
| 6 | 6 | use App\Containers\Payments\Exceptions\ObjectNonChargeableException; |
| 7 | 7 | use App\Containers\Payments\Exceptions\PaymentMethodNotFoundException; |
| 8 | -use App\Containers\Payments\Exceptions\UserNotSetInThePaymentTaskException; |
|
| 9 | 8 | use App\Containers\Paypal\Tasks\ChargeWithPaypalTask; |
| 10 | 9 | use App\Containers\Stripe\Tasks\ChargeWithStripeTask; |
| 11 | 10 | use App\Containers\User\Models\User; |
@@ -35,13 +35,13 @@ |
||
| 35 | 35 | */ |
| 36 | 36 | public function login($email, $password, $remember = false) |
| 37 | 37 | { |
| 38 | - if($remember){ |
|
| 38 | + if ($remember) { |
|
| 39 | 39 | $remember = true; |
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | $correct = $this->auth->attempt(['email' => $email, 'password' => $password], $remember); |
| 43 | 43 | |
| 44 | - if(!$correct){ |
|
| 44 | + if (!$correct) { |
|
| 45 | 45 | throw new AuthenticationFailedException(); |
| 46 | 46 | } |
| 47 | 47 | |
@@ -38,9 +38,8 @@ |
||
| 38 | 38 | |
| 39 | 39 | /** |
| 40 | 40 | * @param $agentId |
| 41 | - * @param null $platform |
|
| 42 | - * @param null $device |
|
| 43 | - * @param bool|false $login |
|
| 41 | + * @param string $platform |
|
| 42 | + * @param string $device |
|
| 44 | 43 | * |
| 45 | 44 | * @return mixed |
| 46 | 45 | */ |
@@ -48,7 +48,7 @@ |
||
| 48 | 48 | { |
| 49 | 49 | $user = $this->findUserService->byAgentId($agentId); |
| 50 | 50 | |
| 51 | - if(!$user){ |
|
| 51 | + if (!$user) { |
|
| 52 | 52 | $user = $this->createUserService->byAgent($agentId, $device, $platform); |
| 53 | 53 | } |
| 54 | 54 | |