Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only show unit of measurement if we have it and if the state is not a string while managing sensors #3685

Merged
merged 2 commits into from
Jul 21, 2023

Conversation

dshokouhi
Copy link
Member

Summary

Noticed that sometimes we were showing unit of measurement when the state was not numeric, so now we will hide the units to show the string properly.

Screenshots

Link to pull request in Documentation repository

Documentation: home-assistant/companion.home-assistant#

Any other notes

@dshokouhi dshokouhi changed the title Only show unit of measurement if we have it and if the state is not a string Only show unit of measurement if we have it and if the state is not a string while managing sensors Jul 20, 2023
@jpelgrom
Copy link
Member

You don't need to add parentheses, looks good otherwise.

@dshokouhi
Copy link
Member Author

You don't need to add parentheses, looks good otherwise.

android studio complained and initially the code did not work so I assumed it needed :)

@jpelgrom
Copy link
Member

Works fine without here, using latest stable Android Studio release?

@JBassett JBassett merged commit 8cc594e into home-assistant:master Jul 21, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants