mirror of
https://github.com/koush/scrypted.git
synced 2026-05-31 00:30:30 +01:00
watch for deleted devices
This commit is contained in:
@@ -49,6 +49,10 @@ export class PluginHost {
|
||||
|
||||
for (const device of Object.values(this.scrypted.devices)) {
|
||||
const pluginDevice = this.scrypted.pluginDevices[device.handler.id];
|
||||
if (!pluginDevice) {
|
||||
console.warn('PluginDevice missing?', device.handler.id);
|
||||
continue;
|
||||
}
|
||||
for (const mixin of getState(pluginDevice, ScryptedInterfaceProperty.mixins) || []) {
|
||||
if (this.scrypted.findPluginDeviceById(mixin).pluginId === this.pluginId) {
|
||||
device.handler.invalidate();
|
||||
|
||||
Reference in New Issue
Block a user