Skip to content

Commit 357c568

Browse files
chore: headers allow credentials for cookies
1 parent 0dbc939 commit 357c568

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/App.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@ public static function create($dir) {
1818

1919
// Header All Allows
2020
header("Access-Control-Allow-Origin: {$_ENV['CORS_ORIGIN']}");
21+
header("Access-Control-Allow-Credentials: true");
2122
header("Content-Type: application/json; charset=UTF-8");
2223
header("Access-Control-Allow-Methods: POST, GET, PUT, DELETE");
23-
header("Access-Control-Allow-Headers: Content-Type, Access-Control-Allow-Headers, Authorization, X-Requested-With");
24+
header("Access-Control-Allow-Headers: Content-Type, Access-Control-Allow-Headers, Authorization, X-Requested-With, Access-Control-Allow-Credentials");
2425

2526
// Database Connection
2627
Database::connection();

0 commit comments

Comments
 (0)