fix socket.io cors errors, see breaking change since socket.io v3 https://socket.io/docs/v3/handling-cors/

This commit is contained in:
Karsten Hassel 2021-01-09 22:50:37 +01:00
parent b177a56fa2
commit 2deab31187
2 changed files with 4 additions and 1 deletions

View File

@ -27,6 +27,7 @@ _This release is scheduled to be released on 2021-04-01._
### Fixed
- Added default log levels to stop calendar log spamming.
- Fix socket.io cors errors, see [breaking change since socket.io v3](https://socket.io/docs/v3/handling-cors/)
## [2.14.0] - 2021-01-01

View File

@ -27,7 +27,9 @@ function Server(config, callback) {
} else {
server = require("http").Server(app);
}
const io = require("socket.io")(server);
const io = require("socket.io")(server, {
cors: {}
});
Log.log(`Starting server on port ${port} ... `);