diff --git a/main.py b/main.py index ccaf860..e8a0d16 100644 --- a/main.py +++ b/main.py @@ -614,6 +614,12 @@ def podcast_rss(station: str, slug_with_ext: str, request: Request, db: Session @app.get("/live/{station}") def live_stream_redirect(station: str, db: Session = Depends(db_session)): + # Usuwamy sztuczne rozszerzenia dodane dla Mopidy + if station.endswith(".aac"): + station = station[:-4] + elif station.endswith(".mp3"): + station = station[:-4] + if station == "radio357": config_url = db.query(Config).filter_by(key="r357_live_url").first() target_url = config_url.value if config_url else "https://stream.rcs.revma.com/ye5kghkgcm0uv"