From ecce9eafd25d83f8fd83c111590ce2fcd4cad65c Mon Sep 17 00:00:00 2001 From: Mark Haslinghuis Date: Sat, 20 Apr 2024 22:15:27 +0200 Subject: [PATCH] Fix race condition --- src/js/serial_backend.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/serial_backend.js b/src/js/serial_backend.js index b8d17283da..10067c8296 100644 --- a/src/js/serial_backend.js +++ b/src/js/serial_backend.js @@ -150,7 +150,7 @@ export function initializeSerialBackend() { finishClose(toggleStatus); } - mspHelper.setArmingEnabled(true, false, onFinishCallback); + mspHelper?.setArmingEnabled(true, false, onFinishCallback); } } }