Skip to content

Commit

Permalink
Small tweak to HLSPlaylist exception
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelveldt committed Oct 19, 2024
1 parent 77bee8d commit 2802bc0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion music_assistant/server/helpers/playlists.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,9 @@ async def fetch_playlist(
raise InvalidDataError(msg) from err

if raise_on_hls and "#EXT-X-VERSION:" in playlist_data or "#EXT-X-STREAM-INF:" in playlist_data:
raise IsHLSPlaylist(encrypted="#EXT-X-KEY:" in playlist_data)
exc = IsHLSPlaylist()
exc.encrypted = "#EXT-X-KEY:" in playlist_data
raise exc

if url.endswith((".m3u", ".m3u8")):
playlist = parse_m3u(playlist_data)
Expand Down

0 comments on commit 2802bc0

Please sign in to comment.