Skip to content

Commit 5eac3a9

Browse files
committed
Apply fixes from StyleCI
1 parent 203b96f commit 5eac3a9

16 files changed

+61
-61
lines changed

app/Exceptions/Handler.php

-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ class Handler extends ExceptionHandler
5050
public function register(): void
5151
{
5252
$this->reportable(function (Throwable $e) {
53-
5453
$enableEmailExceptions = config('exceptions.emailExceptionEnabled');
5554

5655
if ($enableEmailExceptions === '') {

app/Http/Controllers/Auth/NewPasswordController.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ public function create(Request $request): View
3030
public function store(Request $request): RedirectResponse
3131
{
3232
$request->validate([
33-
'token' => ['required'],
34-
'email' => ['required', 'email'],
33+
'token' => ['required'],
34+
'email' => ['required', 'email'],
3535
'password' => ['required', 'confirmed', Rules\Password::defaults()],
3636
]);
3737

@@ -42,7 +42,7 @@ public function store(Request $request): RedirectResponse
4242
$request->only('email', 'password', 'password_confirmation', 'token'),
4343
function ($user) use ($request) {
4444
$user->forceFill([
45-
'password' => Hash::make($request->password),
45+
'password' => Hash::make($request->password),
4646
'remember_token' => Str::random(60),
4747
])->save();
4848

app/Http/Controllers/Auth/PasswordController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public function update(Request $request): RedirectResponse
1717
{
1818
$validated = $request->validateWithBag('updatePassword', [
1919
'current_password' => ['required', 'current_password'],
20-
'password' => ['required', Password::defaults(), 'confirmed'],
20+
'password' => ['required', Password::defaults(), 'confirmed'],
2121
]);
2222

2323
$request->user()->update([

app/Http/Controllers/Auth/RegisteredUserController.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,14 @@ public function create(): View
3131
public function store(Request $request): RedirectResponse
3232
{
3333
$request->validate([
34-
'name' => ['required', 'string', 'max:255'],
35-
'email' => ['required', 'string', 'email', 'max:255', 'unique:'.User::class],
34+
'name' => ['required', 'string', 'max:255'],
35+
'email' => ['required', 'string', 'email', 'max:255', 'unique:'.User::class],
3636
'password' => ['required', 'confirmed', Rules\Password::defaults()],
3737
]);
3838

3939
$user = User::create([
40-
'name' => $request->name,
41-
'email' => $request->email,
40+
'name' => $request->name,
41+
'email' => $request->email,
4242
'password' => Hash::make($request->password),
4343
]);
4444

app/Http/Requests/Auth/LoginRequest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public function authorize(): bool
2727
public function rules(): array
2828
{
2929
return [
30-
'email' => ['required', 'string', 'email'],
30+
'email' => ['required', 'string', 'email'],
3131
'password' => ['required', 'string'],
3232
];
3333
}

app/Providers/AuthServiceProvider.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
namespace App\Providers;
44

5-
use Illuminate\Support\Facades\Gate;
65
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
6+
use Illuminate\Support\Facades\Gate;
77

88
class AuthServiceProvider extends ServiceProvider
99
{

app/Providers/EventServiceProvider.php

+1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ class EventServiceProvider extends ServiceProvider
2626
'SocialiteProviders\\LinkedIn\\LinkedInExtendSocialite@handle',
2727
],
2828
];
29+
2930
/**
3031
* Register any events for your application.
3132
*/

config/app.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@
55
use Collective\Html\FormFacade;
66
use Collective\Html\HtmlFacade;
77
use Creativeorange\Gravatar\Facades\Gravatar;
8-
use Laravel\Socialite\Facades\Socialite;
98
use Illuminate\Support\Facades\Facade;
109
use Illuminate\Support\Facades\Input;
1110
use Illuminate\Support\Facades\Redis;
1211
use Intervention\Image\Facades\Image;
1312
use jeremykenedy\Uuid\Uuid;
13+
use Laravel\Socialite\Facades\Socialite;
1414

1515
return [
1616

config/broadcasting.php

+8-8
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,16 @@
3131
'connections' => [
3232

3333
'pusher' => [
34-
'driver' => 'pusher',
35-
'key' => env('PUSHER_APP_KEY'),
36-
'secret' => env('PUSHER_APP_SECRET'),
37-
'app_id' => env('PUSHER_APP_ID'),
34+
'driver' => 'pusher',
35+
'key' => env('PUSHER_APP_KEY'),
36+
'secret' => env('PUSHER_APP_SECRET'),
37+
'app_id' => env('PUSHER_APP_ID'),
3838
'options' => [
39-
'host' => env('PUSHER_HOST') ?: 'api-'.env('PUSHER_APP_CLUSTER', 'mt1').'.pusher.com',
40-
'port' => env('PUSHER_PORT', 443),
41-
'scheme' => env('PUSHER_SCHEME', 'https'),
39+
'host' => env('PUSHER_HOST') ?: 'api-'.env('PUSHER_APP_CLUSTER', 'mt1').'.pusher.com',
40+
'port' => env('PUSHER_PORT', 443),
41+
'scheme' => env('PUSHER_SCHEME', 'https'),
4242
'encrypted' => true,
43-
'useTLS' => env('PUSHER_SCHEME', 'https') === 'https',
43+
'useTLS' => env('PUSHER_SCHEME', 'https') === 'https',
4444
],
4545
'client_options' => [
4646
// Guzzle client options: https://docs.guzzlephp.org/en/stable/request-options.html

config/logging.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232

3333
'deprecations' => [
3434
'channel' => env('LOG_DEPRECATIONS_CHANNEL', 'null'),
35-
'trace' => false,
35+
'trace' => false,
3636
],
3737

3838
/*

config/queue.php

+23-23
Original file line numberDiff line numberDiff line change
@@ -35,39 +35,39 @@
3535
],
3636

3737
'database' => [
38-
'driver' => 'database',
39-
'table' => 'jobs',
40-
'queue' => 'default',
41-
'retry_after' => 90,
38+
'driver' => 'database',
39+
'table' => 'jobs',
40+
'queue' => 'default',
41+
'retry_after' => 90,
4242
'after_commit' => false,
4343
],
4444

4545
'beanstalkd' => [
46-
'driver' => 'beanstalkd',
47-
'host' => 'localhost',
48-
'queue' => 'default',
49-
'retry_after' => 90,
50-
'block_for' => 0,
46+
'driver' => 'beanstalkd',
47+
'host' => 'localhost',
48+
'queue' => 'default',
49+
'retry_after' => 90,
50+
'block_for' => 0,
5151
'after_commit' => false,
5252
],
5353

5454
'sqs' => [
55-
'driver' => 'sqs',
56-
'key' => env('AWS_ACCESS_KEY_ID'),
57-
'secret' => env('AWS_SECRET_ACCESS_KEY'),
58-
'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'),
59-
'queue' => env('SQS_QUEUE', 'default'),
60-
'suffix' => env('SQS_SUFFIX'),
61-
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
55+
'driver' => 'sqs',
56+
'key' => env('AWS_ACCESS_KEY_ID'),
57+
'secret' => env('AWS_SECRET_ACCESS_KEY'),
58+
'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'),
59+
'queue' => env('SQS_QUEUE', 'default'),
60+
'suffix' => env('SQS_SUFFIX'),
61+
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
6262
'after_commit' => false,
6363
],
6464

6565
'redis' => [
66-
'driver' => 'redis',
67-
'connection' => 'default',
68-
'queue' => env('REDIS_QUEUE', 'default'),
69-
'retry_after' => 90,
70-
'block_for' => null,
66+
'driver' => 'redis',
67+
'connection' => 'default',
68+
'queue' => env('REDIS_QUEUE', 'default'),
69+
'retry_after' => 90,
70+
'block_for' => null,
7171
'after_commit' => false,
7272
],
7373

@@ -92,9 +92,9 @@
9292
*/
9393

9494
'failed' => [
95-
'driver' => env('QUEUE_FAILED_DRIVER', 'database-uuids'),
95+
'driver' => env('QUEUE_FAILED_DRIVER', 'database-uuids'),
9696
'database' => env('DB_CONNECTION', 'mysql'),
97-
'table' => 'failed_jobs',
97+
'table' => 'failed_jobs',
9898
],
9999

100100
];

config/sanctum.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161

6262
'middleware' => [
6363
'verify_csrf_token' => App\Http\Middleware\VerifyCsrfToken::class,
64-
'encrypt_cookies' => App\Http\Middleware\EncryptCookies::class,
64+
'encrypt_cookies' => App\Http\Middleware\EncryptCookies::class,
6565
],
6666

6767
];

config/services.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -15,18 +15,18 @@
1515
*/
1616

1717
'mailgun' => [
18-
'domain' => env('MAILGUN_DOMAIN'),
19-
'secret' => env('MAILGUN_SECRET'),
18+
'domain' => env('MAILGUN_DOMAIN'),
19+
'secret' => env('MAILGUN_SECRET'),
2020
'endpoint' => env('MAILGUN_ENDPOINT', 'api.mailgun.net'),
21-
'scheme' => 'https',
21+
'scheme' => 'https',
2222
],
2323

2424
'postmark' => [
2525
'token' => env('POSTMARK_TOKEN'),
2626
],
2727

2828
'ses' => [
29-
'key' => env('AWS_ACCESS_KEY_ID'),
29+
'key' => env('AWS_ACCESS_KEY_ID'),
3030
'secret' => env('AWS_SECRET_ACCESS_KEY'),
3131
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
3232
],

database/factories/UserFactory.php

+9-9
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,15 @@ public function definition(): array
2121
$userRole = Role::whereName('User')->first();
2222

2323
return [
24-
'name' => fake()->name(),
25-
'first_name' => fake()->firstName,
26-
'last_name' => fake()->lastName,
27-
'email' => fake()->unique()->safeEmail(),
28-
'email_verified_at' => now(),
29-
'password' => bcrypt('secret'),
30-
'token' => str_random(64),
31-
'activated' => true,
32-
'remember_token' => Str::random(10),
24+
'name' => fake()->name(),
25+
'first_name' => fake()->firstName,
26+
'last_name' => fake()->lastName,
27+
'email' => fake()->unique()->safeEmail(),
28+
'email_verified_at' => now(),
29+
'password' => bcrypt('secret'),
30+
'token' => str_random(64),
31+
'activated' => true,
32+
'remember_token' => Str::random(10),
3333
'signup_ip_address' => fake()->ipv4,
3434
'signup_confirmation_ip_address' => fake()->ipv4,
3535
];

routes/web.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
Route::get('/home', [
5858
'as' => 'public.home',
5959
'uses' => 'App\Http\Controllers\UserController@index',
60-
'name' => 'home'
60+
'name' => 'home',
6161
]);
6262

6363
// Show users profile - viewable by other users.

tests/Feature/Auth/AuthenticationTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public function test_users_can_authenticate_using_the_login_screen(): void
2323
$user = User::factory()->create();
2424

2525
$response = $this->post('/login', [
26-
'email' => $user->email,
26+
'email' => $user->email,
2727
'password' => 'password',
2828
]);
2929

@@ -36,7 +36,7 @@ public function test_users_can_not_authenticate_with_invalid_password(): void
3636
$user = User::factory()->create();
3737

3838
$this->post('/login', [
39-
'email' => $user->email,
39+
'email' => $user->email,
4040
'password' => 'wrong-password',
4141
]);
4242

0 commit comments

Comments
 (0)