enkama / hass-variables

Home Assistant variables component
89 stars 12 forks source link

How to remove an attribute of a variable with restore true #100

Closed pickonedev closed 9 months ago

pickonedev commented 9 months ago

Hi!

If I have a yaml sensor with attributes, which have the restore option to true. How can I call the service to remove a specific attribute from the sensor?

I have tried to replace attribute with no value, but no luck.

Thank you!

pickonedev commented 9 months ago

@enkama , @Snuffy2 any idea, please?

Thank you!

pickonedev commented 9 months ago

It's ok, I have solved the problem. All you need is to call the service with "replace_attributes" and empty attributes.