@@ -8,7 +8,7 @@ |
||
8 | 8 | { |
9 | 9 | public function up(): void |
10 | 10 | { |
11 | - Schema::create('wrong_emails', function (Blueprint $table) { |
|
11 | + Schema::create('wrong_emails', function(Blueprint $table) { |
|
12 | 12 | $table->bigIncrements('id'); |
13 | 13 | $table->string('email', 60); |
14 | 14 | $table->string('problem_type', 30); |
@@ -2,6 +2,6 @@ |
||
2 | 2 | |
3 | 3 | use Illuminate\Support\Facades\Route; |
4 | 4 | |
5 | -if (! config('aws-ses-bounce-complaint-handler.via_sqs')) { |
|
5 | +if (!config('aws-ses-bounce-complaint-handler.via_sqs')) { |
|
6 | 6 | Route::post('amazon-sns/notifications', '\ag84ark\AwsSesBounceComplaintHandler\AwsSesBounceComplaintHandler@handleBounceOrComplaint')->middleware('api'); |
7 | 7 | } |
@@ -32,7 +32,7 @@ |
||
32 | 32 | $this->mergeConfigFrom(__DIR__.'/../config/aws-ses-bounce-complaint-handler.php', 'aws-ses-bounce-complaint-handler'); |
33 | 33 | |
34 | 34 | // Register the service the package provides. |
35 | - $this->app->singleton('aws-ses-bounce-complaint-handler', function ($app) { |
|
35 | + $this->app->singleton('aws-ses-bounce-complaint-handler', function($app) { |
|
36 | 36 | return new AwsSesBounceComplaintHandler(); |
37 | 37 | }); |
38 | 38 | } |
@@ -14,11 +14,11 @@ discard block |
||
14 | 14 | { |
15 | 15 | public function handleBounceOrComplaint(Request $request): JsonResponse |
16 | 16 | { |
17 | - if (! $request->json()) { |
|
17 | + if (!$request->json()) { |
|
18 | 18 | return Response::json(['status' => 422, 'message' => 'error'], 422); |
19 | 19 | } |
20 | 20 | |
21 | - if (! $this->canPass($request)) { |
|
21 | + if (!$this->canPass($request)) { |
|
22 | 22 | return Response::json(['status' => 403, 'message' => 'error'], 403); |
23 | 23 | } |
24 | 24 | |
@@ -30,11 +30,11 @@ discard block |
||
30 | 30 | |
31 | 31 | $message = $this->getMessageData($request, $data); |
32 | 32 | |
33 | - if (! count($message)) { |
|
33 | + if (!count($message)) { |
|
34 | 34 | return Response::json(['status' => 422, 'data' => $data], 422); |
35 | 35 | } |
36 | 36 | |
37 | - if (! isset($message['notificationType'])) { |
|
37 | + if (!isset($message['notificationType'])) { |
|
38 | 38 | return Response::json(['status' => 200, 'message' => 'no data']); |
39 | 39 | } |
40 | 40 | |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | ->get(); |
53 | 53 | |
54 | 54 | foreach ($emails as $wrongEmail) { |
55 | - if (! $wrongEmail->canBouncedSend()) { |
|
55 | + if (!$wrongEmail->canBouncedSend()) { |
|
56 | 56 | return false; |
57 | 57 | } |
58 | 58 | } |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | } |
86 | 86 | |
87 | 87 | $secret = config('aws-ses-bounce-complaint-handler.route_secret'); |
88 | - if (! $secret) { |
|
88 | + if (!$secret) { |
|
89 | 89 | return true; |
90 | 90 | } |
91 | 91 |
@@ -3,7 +3,7 @@ |
||
3 | 3 | use ag84ark\AwsSesBounceComplaintHandler\Models\WrongEmail; |
4 | 4 | use Faker\Generator; |
5 | 5 | |
6 | -$factory->define(WrongEmail::class, function (Generator $faker) { |
|
6 | +$factory->define(WrongEmail::class, function(Generator $faker) { |
|
7 | 7 | return [ |
8 | 8 | 'email' => $faker->email, |
9 | 9 | 'repeated_attempts' => $faker->randomNumber(1), |