fix(core): update
This commit is contained in:
parent
ba38dae64f
commit
38058aba57
@ -3,6 +3,6 @@
|
||||
*/
|
||||
export const commitinfo = {
|
||||
name: '@pushrocks/smartsocket',
|
||||
version: '2.0.12',
|
||||
version: '2.0.13',
|
||||
description: 'easy and secure websocket communication'
|
||||
}
|
||||
|
@ -47,7 +47,13 @@ export class Smartsocket {
|
||||
*/
|
||||
public async start() {
|
||||
const socketIoModule = await this.smartenv.getSafeNodeModule('socket.io');
|
||||
this.io = new socketIoModule.Server(await this.socketServer.getServerForSocketIo());
|
||||
this.io = new socketIoModule.Server(await this.socketServer.getServerForSocketIo(), {
|
||||
cors: {
|
||||
allowedHeaders: '*',
|
||||
methods: '*',
|
||||
origin: '*',
|
||||
}
|
||||
});
|
||||
await this.socketServer.start();
|
||||
this.io.on('connection', (socketArg) => {
|
||||
this._handleSocketConnection(socketArg);
|
||||
|
Loading…
Reference in New Issue
Block a user