Skip to content

Commit bf1ce89

Browse files
committed
fix update
1 parent fea143f commit bf1ce89

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

‎back/src/dals/room/repository/room.repository.ts‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
import { RoomInfo, RoomContext } from 'dals';
22

33
export const isRoomAvailable = async (room: string): Promise<boolean> => {
4-
const roomAvailable = !(await RoomContext.exists({ room }));
5-
return roomAvailable;
4+
return (await RoomContext.countDocuments({ room: room })) === 0;
65
};
76

87
export const saveRoomInfo = async (

0 commit comments

Comments
 (0)