Apply Laravel coding style

Shift automatically applies the Laravel coding style - which uses the PSR-12 coding style as a base with some minor additions.

You may customize the code style applied by configuring [Pint](https://laravel.com/docs/pint), [PHP CS Fixer](https://github.com/FriendsOfPHP/PHP-CS-Fixer), or [PHP CodeSniffer](https://github.com/squizlabs/PHP_CodeSniffer) for your project root.

For more information on customizing the code style applied by Shift, [watch this short video](https://laravelshift.com/videos/shift-code-style).
This commit is contained in:
Shift
2023-02-19 16:18:46 +00:00
committed by HolgerHatGarKeineNode
parent a15ca4a2bc
commit 5776b01d15
333 changed files with 4915 additions and 4967 deletions

View File

@@ -14,22 +14,21 @@ class UpdateUserProfileInformation implements UpdatesUserProfileInformation
*
* @param mixed $user
* @param array $input
*
* @return void
*/
public function update($user, array $input)
{
Validator::make($input, [
'name' => ['required', 'string', 'max:255'],
'name' => ['required', 'string', 'max:255'],
'lightning_address' => ['nullable', 'string'],
'lnurl' => ['nullable', 'string'],
'node_id' => ['nullable', 'string', 'max:66'],
'timezone' => ['required', 'string'],
'email' => [
'lnurl' => ['nullable', 'string'],
'node_id' => ['nullable', 'string', 'max:66'],
'timezone' => ['required', 'string'],
'email' => [
'nullable', 'email', 'max:255', Rule::unique('users')
->ignore($user->id)
->ignore($user->id),
],
'photo' => ['nullable', 'mimes:jpg,jpeg,png,gif', 'max:10240'],
'photo' => ['nullable', 'mimes:jpg,jpeg,png,gif', 'max:10240'],
])
->validateWithBag('updateProfileInformation');
@@ -42,12 +41,12 @@ class UpdateUserProfileInformation implements UpdatesUserProfileInformation
$this->updateVerifiedUser($user, $input);
} else {
$user->forceFill([
'name' => $input['name'],
'name' => $input['name'],
'lightning_address' => $input['lightning_address'],
'lnurl' => $input['lnurl'],
'node_id' => $input['node_id'],
'email' => $input['email'],
'timezone' => $input['timezone'],
'lnurl' => $input['lnurl'],
'node_id' => $input['node_id'],
'email' => $input['email'],
'timezone' => $input['timezone'],
])
->save();
}
@@ -58,18 +57,17 @@ class UpdateUserProfileInformation implements UpdatesUserProfileInformation
*
* @param mixed $user
* @param array $input
*
* @return void
*/
protected function updateVerifiedUser($user, array $input)
{
$user->forceFill([
'name' => $input['name'],
'name' => $input['name'],
'lightning_address' => $input['lightning_address'],
'lnurl' => $input['lnurl'],
'node_id' => $input['node_id'],
'email' => $input['email'],
'timezone' => $input['timezone'],
'lnurl' => $input['lnurl'],
'node_id' => $input['node_id'],
'email' => $input['email'],
'timezone' => $input['timezone'],
'email_verified_at' => null,
])
->save();