Skip to content

Commit

Permalink
fix: um, actually...
Browse files Browse the repository at this point in the history
  • Loading branch information
lewxdev committed Aug 21, 2024
1 parent 9854159 commit d14caf4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@ async function main() {
});

io.on("connection", async (socket) => {
if (field.isComplete) {
field = await Field.create(field.size + 10);
await redis.resetSessions();
io.emit("sessionState", "alive");
}

await redis.setSession(socket.data.sessionId, "alive");
socket.emit("session", socket.data.sessionId);
socket.emit("sessionState", "alive");
Expand Down

0 comments on commit d14caf4

Please sign in to comment.