Stop location scrobbles properly

This commit is contained in:
2023-12-09 21:32:13 +01:00
parent 478780e9b3
commit 96ca2f5602

View File

@ -703,9 +703,9 @@ class Scrobble(TimeStampedModel):
f"No - We've moved, start a new scrobble: {self.media_obj}"
)
# TODO maybe this should go to `update`?
last = self.previous_all
last.played_to_completion = True
last.save(update_fields=["played_to_completion"])
self.played_to_completion = True
self.stop_timestamp = timezone.now()
self.save(update_fields=["played_to_completion", "stop_timestamp"])
updatable = False
return updatable