Fix bug with stopping wrong scrobble

This commit is contained in:
2023-12-09 23:14:50 +01:00
parent e5ed265e8f
commit 356579f78a

View File

@ -706,10 +706,8 @@ class Scrobble(TimeStampedModel):
logger.info(
f"No - We've moved, start a new scrobble: {self.media_obj}"
)
# TODO maybe this should go to `update`?
self.played_to_completion = True
self.stop_timestamp = timezone.now()
self.save(update_fields=["played_to_completion", "stop_timestamp"])
# Stop the previous location scrobble
self.previous_all.stop()
updatable = False
return updatable