Skip to content

Commit

Permalink
refactor: rename get_dsp_details to get_player_dsp_details
Browse files Browse the repository at this point in the history
  • Loading branch information
maximmaxim345 committed Jan 16, 2025
1 parent f87153d commit f23adb4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions music_assistant/helpers/audio.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ async def strip_silence(
return stripped_data


def get_dsp_details(mass: MusicAssistant, player: Player) -> DSPDetails:
def get_player_dsp_details(mass: MusicAssistant, player: Player) -> DSPDetails:
"""Return DSP details of single a player."""
dsp_config = mass.config.get_player_dsp_config(player.player_id)
dsp_state = DSPState.ENABLED if dsp_config.enabled else DSPState.DISABLED
Expand Down Expand Up @@ -216,15 +216,15 @@ def get_stream_dsp_details(
# We skip the PlayerGroups as they don't provide an audio output
# by themselves, but only sync other players.
if not player.provider.startswith("player_group"):
details = get_dsp_details(mass, player)
details = get_player_dsp_details(mass, player)
details.is_leader = True
dsp[player.player_id] = details

if player and player.group_childs:
# grouped playback, get DSP details for each player in the group
for child_id in player.group_childs:
if child_player := mass.players.get(child_id):
dsp[child_id] = get_dsp_details(mass, child_player)
dsp[child_id] = get_player_dsp_details(mass, child_player)
return dsp


Expand Down

0 comments on commit f23adb4

Please sign in to comment.