Explorar o código

[music] Fixes missing jellyfin ts converter

Colin Powell hai 1 mes
pai
achega
27f50baf5d
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      vrobbler/apps/scrobbles/scrobblers.py

+ 4 - 1
vrobbler/apps/scrobbles/scrobblers.py

@@ -22,6 +22,7 @@ from scrobbles.constants import (
     SCROBBLE_CONTENT_URLS,
 )
 from scrobbles.models import Scrobble
+from scrobbles.utils import convert_to_seconds
 from sports.models import SportEvent
 from sports.thesportsdb import lookup_event_from_thesportsdb
 from tasks.models import Task
@@ -117,7 +118,9 @@ def jellyfin_scrobble_media(
             title=post_data.get("Name", ""),
             artist_name=post_data.get("Artist", ""),
             album_name=post_data.get("Album", ""),
-            run_time_seconds=post_data.get("RunTime", 900000),
+            run_time_seconds=convert_to_seconds(
+                post_data.get("RunTime", 900000)
+            ),
             musicbrainz_id=post_data.get("Provider_musicbrainztrack", ""),
         )
         # A hack because we don't worry about updating music ... we either finish it or we don't