Revert "rector: arrrrr"

This reverts commit 16c0cd10d8.
This commit is contained in:
Andras Bacsai
2025-01-07 15:31:43 +01:00
parent da07b4fdcf
commit 1fe4dd722b
349 changed files with 3689 additions and 4184 deletions

View File

@@ -3,7 +3,6 @@
namespace App\Http\Controllers;
use App\Models\User;
use Exception;
use Illuminate\Support\Facades\Auth;
use Symfony\Component\HttpKernel\Exception\HttpException;
@@ -27,7 +26,7 @@ class OauthController extends Controller
abort(403, 'Registration is disabled');
}
$user = User::query()->create([
$user = User::create([
'name' => $oauthUser->name,
'email' => $oauthUser->email,
]);
@@ -35,7 +34,7 @@ class OauthController extends Controller
Auth::login($user);
return redirect('/');
} catch (Exception $e) {
} catch (\Exception $e) {
$errorCode = $e instanceof HttpException ? 'auth.failed' : 'auth.failed.callback';
return redirect()->route('login')->withErrors([__($errorCode)]);