1
0
Fork 0
mirror of https://github.com/bastienwirtz/homer.git synced 2026-07-24 16:41:56 +00:00

Update Message.vue

This commit is contained in:
mangobiche 2025-04-15 17:04:40 -05:00 committed by GitHub
parent b40d008400
commit ae8d9efdd4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -79,6 +79,10 @@ export default {
mapRemoteMessage: function (message) {
let mapped = {};
// If the msg is an array, take the frist value
if (Array.isArray(message)) message = message[0];
// map property from message into mapped according to mapping config (only if field has a value):
for (const prop in this.item.mapping)
if (message[this.item.mapping[prop]])