From f78ffd16883f065a3ef47b08941bef896138a53f Mon Sep 17 00:00:00 2001 From: Kim Ying <15070078+kimprice@users.noreply.github.com> Date: Thu, 10 Aug 2023 17:20:20 -0500 Subject: [PATCH] remove preliminary null check (#9635) --- multiplayer/src/services/simHost.ts | 2 +- pxtrunner/runner.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/multiplayer/src/services/simHost.ts b/multiplayer/src/services/simHost.ts index 47a390532366..be52c0706446 100644 --- a/multiplayer/src/services/simHost.ts +++ b/multiplayer/src/services/simHost.ts @@ -375,7 +375,7 @@ export async function simulateAsync( driver.run(js, runOptions); } if (msg.command == "setstate") { - if (msg.stateKey && msg.stateValue != null) { + if (msg.stateKey) { setStoredState(runOpts, msg.stateKey, msg.stateValue); } } diff --git a/pxtrunner/runner.ts b/pxtrunner/runner.ts index a5a56683af0e..7bb57b15a349 100644 --- a/pxtrunner/runner.ts +++ b/pxtrunner/runner.ts @@ -391,7 +391,7 @@ namespace pxt.runner { simDriver.run(js, runOptions); } if (msg.command == "setstate") { - if (msg.stateKey && msg.stateValue != null) { + if (msg.stateKey) { setStoredState(simOptions.id, msg.stateKey, msg.stateValue) } }