refactor(web): make the shared origin list read-only (#200)
ALLOWED_ORIGINS was private to ws.ts; it is now exported by origin.ts and read by the routes too. Typed `readonly string[]`, so that no module can add an origin to it by mistake. Same two values, same behaviour. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
parent
81a499eaf4
commit
337a8e9240
1 changed files with 1 additions and 1 deletions
|
|
@ -8,7 +8,7 @@
|
|||
//
|
||||
// No import here: server.ts bundles ws.ts, and this module with it, apart
|
||||
// from the Next routes (web/Dockerfile, esbuild).
|
||||
export const ALLOWED_ORIGINS = [
|
||||
export const ALLOWED_ORIGINS: readonly string[] = [
|
||||
'https://liste.lacompagniemaximus.com',
|
||||
'http://localhost:3000',
|
||||
];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue