Enha: wait for mime clue

This commit is contained in:
Grail Finder
2025-05-12 19:41:34 +03:00
parent da8131a0a4
commit f752d2a162
5 changed files with 16 additions and 10 deletions

View File

@ -94,6 +94,10 @@ func HandleExit(w http.ResponseWriter, r *http.Request) {
abortWithError(w, err.Error())
return
}
if fi.Room.IsRunning {
abortWithError(w, "cannot leave when game is running")
return
}
var creatorLeft bool
if fi.Room.CreatorName == fi.State.Username {
creatorLeft = true