Skip to content

Commit

Permalink
Use MAX_VOLUME constant in vlc_telnet (#48491)
Browse files Browse the repository at this point in the history
We also don't need to call `int()` anymore due to underlying fixes in
the python-vlc-telnet library.

I believe this is the last item extracted from PR #44776.
  • Loading branch information
dmcc authored Mar 30, 2021
1 parent 0082eca commit e47d576
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion homeassistant/components/vlc_telnet/media_player.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def update(self):

if status:
if "volume" in status:
self._volume = int(status["volume"]) / 500.0
self._volume = status["volume"] / MAX_VOLUME
else:
self._volume = None
if "state" in status:
Expand Down

0 comments on commit e47d576

Please sign in to comment.