Skip to content

Commit

Permalink
Fix endpoint added twice to Niko 552-721X2 operation_mode property. K…
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenkk authored and Mephistofeles committed Dec 13, 2022
1 parent 0629ac8 commit f9812ec
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions devices/niko.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,8 @@ const local = {
if (!operationModeLookup.hasOwnProperty(value)) {
throw new Error(`operation_mode was called with an invalid value (${value})`);
} else {
const operationModeProperty = `operation_mode${meta.endpoint_name ? `_${meta.endpoint_name}` : ''}`;
await entity.write('manuSpecificNiko1', {'switchOperationMode': operationModeLookup[value]});
return {state: {[operationModeProperty]: value.toLowerCase()}};
return {state: {operation_mode: value.toLowerCase()}};
}
},
convertGet: async (entity, key, meta) => {
Expand Down

1 comment on commit f9812ec

@sjorge
Copy link

@sjorge sjorge commented on f9812ec Dec 21, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm guessing the fz converter needs updating then as wel as that one still uses operationModeProperty

Please sign in to comment.