fixed cors

This commit is contained in:
AmirHossein Mahmoodi
2025-05-04 12:45:42 +03:30
parent 35bead14b7
commit 0760db111c

View File

@@ -9,10 +9,11 @@ import { SendMessageDto } from './dto/sendMessage.dto';
import { SocketService } from './socket.service'; import { SocketService } from './socket.service';
@WebSocketGateway({ @WebSocketGateway({
namespace: '/notification',
cors: { cors: {
origin: '*', origin: '*',
}, },
// transports: ['websocket'], path: '/notification/socket.io',
}) })
export class SocketGateway implements OnGatewayConnection { export class SocketGateway implements OnGatewayConnection {
@WebSocketServer() @WebSocketServer()