Delete room on end-quiz

This commit is contained in:
MathieuSevignyLavallee 2024-11-11 17:45:30 -05:00
parent db6fa947d7
commit 2c7fd9c828

View file

@ -62,6 +62,8 @@ class WebSocketService {
endQuiz(roomName: string) {
if (this.socket) {
this.socket.emit('end-quiz', { roomName });
//Delete room in mongoDb, roomContainer will be deleted in cleanup
fetch(`/api/room/${roomName}`, { method: 'DELETE' });
}
}