From d7289fe2b076616353d12e628051831bab7d55ac Mon Sep 17 00:00:00 2001 From: Mel Date: Sat, 19 Feb 2022 20:01:14 +0100 Subject: Flip wrong conditional when setting client type --- assets/src/state/constant_state.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'assets/src') diff --git a/assets/src/state/constant_state.ts b/assets/src/state/constant_state.ts index aeda86e..14a187d 100644 --- a/assets/src/state/constant_state.ts +++ b/assets/src/state/constant_state.ts @@ -5,7 +5,7 @@ import { RookType } from "../models/rook_type"; let clientType: RookType = null; export function setClientType(type: RookType) { - if (clientType !== null) { + if (clientType === null) { clientType = type; } else { throw new Error("Tried changing client type after initialization."); -- cgit 1.4.1