@scrypted/server 0.0.97 → 0.0.101
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/event-registry.js +2 -1
- package/dist/event-registry.js.map +1 -1
- package/dist/plugin/plugin-device.js +103 -67
- package/dist/plugin/plugin-device.js.map +1 -1
- package/dist/plugin/plugin-host-api.js +30 -9
- package/dist/plugin/plugin-host-api.js.map +1 -1
- package/dist/plugin/plugin-host.js +2 -14
- package/dist/plugin/plugin-host.js.map +1 -1
- package/dist/runtime.js +40 -2
- package/dist/runtime.js.map +1 -1
- package/dist/services/plugin.js +4 -2
- package/dist/services/plugin.js.map +1 -1
- package/package.json +2 -2
- package/python/plugin-remote.py +3 -1
- package/src/event-registry.ts +3 -1
- package/src/plugin/plugin-device.ts +117 -74
- package/src/plugin/plugin-host-api.ts +31 -9
- package/src/plugin/plugin-host.ts +2 -12
- package/src/runtime.ts +49 -3
- package/src/services/plugin.ts +4 -2
package/src/services/plugin.ts
CHANGED
|
@@ -29,8 +29,10 @@ export class PluginComponent {
|
|
|
29
29
|
const pluginDevice = this.scrypted.findPluginDeviceById(id);
|
|
30
30
|
this.scrypted.stateManager.setPluginDeviceState(pluginDevice, ScryptedInterfaceProperty.mixins, [...new Set(mixins)] || []);
|
|
31
31
|
await this.scrypted.datastore.upsert(pluginDevice);
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
// device may not exist, so force creation.
|
|
33
|
+
this.scrypted.rebuildPluginDeviceMixinTable(id);
|
|
34
|
+
this.scrypted.getDevice(id);
|
|
35
|
+
await this.scrypted.devices[id]?.handler?.ensureProxy();
|
|
34
36
|
}
|
|
35
37
|
async getMixins(id: string) {
|
|
36
38
|
console.warn('legacy use of getMixins, use the mixins property');
|