diff --git a/vrobbler/apps/scrobbles/models.py b/vrobbler/apps/scrobbles/models.py index 8518b0f..cf52f4e 100644 --- a/vrobbler/apps/scrobbles/models.py +++ b/vrobbler/apps/scrobbles/models.py @@ -829,6 +829,7 @@ class Scrobble(TimeStampedModel): ) source = scrobble_data["source"] mtype = media.__class__.__name__ + mopidy_status = scrobble_data.get("mopidy_status", None) logger.info( f"[scrobbling] check for existing scrobble to update ", @@ -853,6 +854,9 @@ class Scrobble(TimeStampedModel): ) return scrobble + if mopidy_status == "stopped": + scrobble.stop() + if scrobble and scrobble.can_be_updated: return scrobble.update(scrobble_data)