Skip to content

Commit e501e3a

Browse files
committed
Fix error on missing thumbnail
1 parent 07ede91 commit e501e3a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mqtt/client.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ class MqttClient {
8989
await this.sendNotification(notificationType, deviceSN, attributes)
9090
}
9191

92-
if (attributes.hasOwnProperty('thumbnail') && attributes.thumbnail.length > 0) {
92+
if (attributes.thumbnail && attributes.thumbnail.length > 0) {
9393
await this.uploadThumbnail(deviceSN, attributes.thumbnail)
9494
}
9595
}

0 commit comments

Comments
 (0)