dedup game end event in bot/board API - closes #61
ignore the move event if the game is finished, because we also get a FinishGame event then.pull/7292/head^2
parent
63a9680ed2
commit
d9a8f7a51b
|
@ -98,7 +98,7 @@ final class GameStateStream(
|
|||
}
|
||||
|
||||
def receive = {
|
||||
case MoveGameEvent(g, _, _) if g.id == id => pushState(g)
|
||||
case MoveGameEvent(g, _, _) if g.id == id && !g.finished => pushState(g)
|
||||
case lila.chat.actorApi.ChatLine(chatId, UserLine(username, _, text, false, false)) =>
|
||||
pushChatLine(username, text, chatId.value.lengthIs == Game.gameIdSize)
|
||||
case FinishGame(g, _, _) if g.id == id => onGameOver(g.some)
|
||||
|
|
Loading…
Reference in New Issue