Update CORS
Signed-off-by: Fred Boniface <fred@fjla.uk>
This commit is contained in:
parent
6a40ff90d0
commit
6cbf91c775
3
app.js
3
app.js
@ -63,8 +63,7 @@ app.use((err, req, res, next) => {
|
|||||||
|
|
||||||
// Global Middleware:
|
// Global Middleware:
|
||||||
app.use(cors({
|
app.use(cors({
|
||||||
origin: [/\.owlboard\.info$/, 'localhost'],
|
origin: [/\.owlboard\.info$/, 'localhost:5173', 'localhost:4173']
|
||||||
methods:'GET,POST,OPTIONS'
|
|
||||||
}));
|
}));
|
||||||
app.use(express.json()); //JSON Parsing for POST Requests
|
app.use(express.json()); //JSON Parsing for POST Requests
|
||||||
app.use(compression()); // Compress API Data if supported by client
|
app.use(compression()); // Compress API Data if supported by client
|
||||||
|
Loading…
Reference in New Issue
Block a user