Treat strings starting with https but not htt as soundtouch media URLs (#101183)
This commit is contained in:
parent
a4a99ce957
commit
31ea00f5c7
1 changed files with 1 additions and 2 deletions
|
@ -3,7 +3,6 @@ from __future__ import annotations
|
|||
|
||||
from functools import partial
|
||||
import logging
|
||||
import re
|
||||
from typing import Any
|
||||
|
||||
from libsoundtouch.device import SoundTouchDevice
|
||||
|
@ -250,7 +249,7 @@ class SoundTouchMediaPlayer(MediaPlayerEntity):
|
|||
) -> None:
|
||||
"""Play a piece of media."""
|
||||
_LOGGER.debug("Starting media with media_id: %s", media_id)
|
||||
if re.match(r"http?://", str(media_id)):
|
||||
if str(media_id).lower().startswith("http://"): # no https support
|
||||
# URL
|
||||
_LOGGER.debug("Playing URL %s", str(media_id))
|
||||
self._device.play_url(str(media_id))
|
||||
|
|
Loading…
Add table
Reference in a new issue