diff --git a/plugins/mqtt/package-lock.json b/plugins/mqtt/package-lock.json index bd25297e7..72d334a79 100644 --- a/plugins/mqtt/package-lock.json +++ b/plugins/mqtt/package-lock.json @@ -1,12 +1,12 @@ { "name": "@scrypted/mqtt", - "version": "0.0.69", + "version": "0.0.71", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@scrypted/mqtt", - "version": "0.0.69", + "version": "0.0.71", "dependencies": { "@types/node": "^16.6.1", "aedes": "^0.46.1", diff --git a/plugins/mqtt/package.json b/plugins/mqtt/package.json index afaba6101..5b680fe79 100644 --- a/plugins/mqtt/package.json +++ b/plugins/mqtt/package.json @@ -41,5 +41,5 @@ "@scrypted/common": "file:../../common", "@types/nunjucks": "^3.2.0" }, - "version": "0.0.69" + "version": "0.0.71" } diff --git a/plugins/mqtt/src/main.ts b/plugins/mqtt/src/main.ts index 31bf2d77c..9d88ff300 100644 --- a/plugins/mqtt/src/main.ts +++ b/plugins/mqtt/src/main.ts @@ -298,7 +298,7 @@ class MqttPublisherMixin extends SettingsMixinDeviceBase { return; } try { - const args = JSON.parse(message.toString()); + const args = JSON.parse(message.toString() || '[]'); await this.device[method](...args); } catch (e) {