From 7f64c80b77f262d5c43b6cd6bf5992ec91384238 Mon Sep 17 00:00:00 2001 From: Giovanni-Josserand Date: Tue, 3 Feb 2026 17:11:41 +0100 Subject: [PATCH] test --- bootstrap/app.php | 3 --- config/cors.php | 2 +- config/sanctum.php | 4 ++-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/bootstrap/app.php b/bootstrap/app.php index 9af070e..8ecbefe 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -14,9 +14,6 @@ return Application::configure(basePath: dirname(__DIR__)) ) ->withMiddleware(function (Middleware $middleware): void { $middleware->statefulApi(); - $middleware->api(prepend: [ - \Illuminate\Http\Middleware\HandleCors::class, - ]); }) ->withExceptions(function (Exceptions $exceptions): void { // diff --git a/config/cors.php b/config/cors.php index c8578a4..3dc4c0d 100644 --- a/config/cors.php +++ b/config/cors.php @@ -19,7 +19,7 @@ return [ 'allowed_methods' => ['*'], - 'allowed_origins' => [env('FRONTEND_URL'), 'http://localhost:5173'], + 'allowed_origins' => ['http://localhost:5173'], 'allowed_origins_patterns' => [], diff --git a/config/sanctum.php b/config/sanctum.php index 63ecc5e..5dcbaf3 100644 --- a/config/sanctum.php +++ b/config/sanctum.php @@ -16,12 +16,12 @@ return [ */ 'stateful' => explode(',', env('SANCTUM_STATEFUL_DOMAINS', sprintf( - '%s%s', + '%s,%s', 'localhost,localhost:5173,127.0.0.1,127.0.0.1:8000,::1', Sanctum::currentApplicationUrlWithPort(), - // Sanctum::currentRequestHost(), ))), + /* |-------------------------------------------------------------------------- | Sanctum Guards