1
0
Fork 0
mirror of https://gitlab.com/futo-org/fcast.git synced 2025-08-06 09:12:50 +00:00

Refractored service registration

This commit is contained in:
Michael Hollister 2025-01-08 23:57:30 -06:00
parent 6b287ad4a6
commit 83259f841d
2 changed files with 35 additions and 143 deletions

View file

@ -26,13 +26,13 @@ window.targetAPI.onDisconnect((_event, value: any) => {
const index = connections.indexOf(value.id);
if (index != -1) {
connections.splice(index, 1);
}
if (connections.length === 0) {
connectionStatusText.textContent = 'Waiting for a connection';
connectionStatusSpinner.style.display = 'inline-block';
connectionStatusCheck.style.display = 'none';
toast("Device disconnected", ToastIcon.INFO);
if (connections.length === 0) {
connectionStatusText.textContent = 'Waiting for a connection';
connectionStatusSpinner.style.display = 'inline-block';
connectionStatusCheck.style.display = 'none';
toast("Device disconnected", ToastIcon.INFO);
}
}
});