diff --git a/package.json b/package.json index 9fac145..c620d4a 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "room-card", - "version": "1.08.03", + "version": "1.08.04", "description": "Show entities in Home Assistant's Lovelace UI", "keywords": [ "home-assistant", diff --git a/src/template.ts b/src/template.ts index 33a654d..013599e 100644 --- a/src/template.ts +++ b/src/template.ts @@ -15,7 +15,7 @@ export const mapTemplate = (entity: RoomCardEntity, config: RoomCardConfig) => { if(templatesWithMatchingName.length > 0) { const templateFromConfig = templatesWithMatchingName[0]; - return { stateObj: entity.stateObj, ...entity, ...templateFromConfig.template }; + return { stateObj: entity.stateObj, ...templateFromConfig.template, ...entity }; } } @@ -34,4 +34,4 @@ export const getTemplateOrAttribute = (attribute: string | number | RoomCardAttr } return attribute; -} \ No newline at end of file +}