oops quick bugfix
This commit is contained in:
parent
8aaa779c44
commit
8c0e56b33a
1 changed files with 1 additions and 1 deletions
|
@ -68,7 +68,7 @@ export async function POST({ request, getClientAddress }) {
|
||||||
console.log("Room added:", JSON.stringify(room, null, 2));
|
console.log("Room added:", JSON.stringify(room, null, 2));
|
||||||
// push every room to the top which starts with `[SUYU OFFICIAL]` and was created with username "suyu"
|
// push every room to the top which starts with `[SUYU OFFICIAL]` and was created with username "suyu"
|
||||||
const suyuRoom = RoomManager.rooms.find((r) => r.roomInfo.name.startsWith("[SUYU OFFICIAL]"));
|
const suyuRoom = RoomManager.rooms.find((r) => r.roomInfo.name.startsWith("[SUYU OFFICIAL]"));
|
||||||
if (suyuRoom && user.username === "suyu") {
|
if (suyuRoom && suyuRoom.host.username === "suyu") {
|
||||||
RoomManager.rooms.splice(RoomManager.rooms.indexOf(suyuRoom), 1);
|
RoomManager.rooms.splice(RoomManager.rooms.indexOf(suyuRoom), 1);
|
||||||
RoomManager.rooms.unshift(suyuRoom);
|
RoomManager.rooms.unshift(suyuRoom);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue