Skip to content

Commit

Permalink
refactor: Remove origin header
Browse files Browse the repository at this point in the history
  • Loading branch information
amiralitaheri committed Sep 6, 2024
1 parent cb193ca commit 96dadb5
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions back/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,7 @@ const server = Bun.serve<PlayerInfo>({
? undefined
: new Response("WebSocket upgrade error", { status: 400 });
}
if (url.pathname === "/health")
return new Response("alive!", {
headers: {
"Access-Control-Allow-Origin": request.headers.get("origin") || "",
},
});
if (url.pathname === "/health") return new Response("alive!");
return new Response("404!", { status: 404 });
},
websocket: {
Expand Down

0 comments on commit 96dadb5

Please sign in to comment.