From 71e3d9de9a9d021a25ec484f72b742be64970bf2 Mon Sep 17 00:00:00 2001 From: smoran425 <38194288+smoran425@users.noreply.github.com> Date: Fri, 2 Jul 2021 14:54:53 +1000 Subject: [PATCH] Update pin-code.js The added 2 lines remove the call button should the user select cancel at the message prompt for the pin code --- Pin Code Lock/pin-code.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Pin Code Lock/pin-code.js b/Pin Code Lock/pin-code.js index df4f487..2f12919 100644 --- a/Pin Code Lock/pin-code.js +++ b/Pin Code Lock/pin-code.js @@ -17,6 +17,7 @@ function onResponse(code) { if (code === PIN_CODE) { console.log('pin correct'); + xapi.config.set('UserInterface Features HideAll', 'False'); } else { console.log('pin failed'); @@ -35,7 +36,10 @@ function listenToEvents() { } }); xapi.status.on('Standby State', (state) => { - if (state === 'Off') askForPin(); + if (state === 'Off') { + xapi.config.set('UserInterface Features HideAll', 'True'); + askForPin(); + } }); }