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:
parent
6b287ad4a6
commit
83259f841d
2 changed files with 35 additions and 143 deletions
|
@ -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);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue