From d5c6d4fc73596cd826182d212bdbd44b6870098f Mon Sep 17 00:00:00 2001 From: khuxkm fbexl Date: Wed, 2 Mar 2022 15:45:58 +0000 Subject: [PATCH] Use song name from AzuraCast instead of from Icecast Sometimes Azura has the metadata correct and Icecast doesn't. --- tilderadio.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tilderadio.py b/tilderadio.py index 69596d0..b694ee4 100644 --- a/tilderadio.py +++ b/tilderadio.py @@ -79,7 +79,7 @@ class Module(ModuleManager.BaseModule): # get the song name directly from icecast icecast_data = utils.http.request(ICECAST_API_BASE + "/status-json.xsl").json() np = icecast_data["icestats"]["source"] - self.song = np[0]["yp_currently_playing"] + self.song = data["now_playing"]["song"]["text"] self.listeners = sum(i["listeners"] for i in np) # azuracast's now playing info is broken