Skip to content

Commit

Permalink
Update playback state as well on product state error
Browse files Browse the repository at this point in the history
  • Loading branch information
mj23000 committed Jan 20, 2023
1 parent 8ff0118 commit a2d34c8
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions custom_components/bangolufsen/media_player.py
Original file line number Diff line number Diff line change
Expand Up @@ -412,10 +412,8 @@ async def bangolufsen_init(self) -> bool:
"Error deserializing product state. Defaulting to fallback state"
)
self._volume = self._client.get_current_volume(async_req=True).get()
playback_state = self._client.get_playback_state(
async_req=True
).get()
self._playback_progress = playback_state.progress
self._playback_state = self._client.get_playback_state(async_req=True).get()
self._playback_progress = self._playback_state.progress

self._last_update = utcnow()

Expand Down

0 comments on commit a2d34c8

Please sign in to comment.