소스 검색

[locations] Do not mark geolocs complete automatically

Colin Powell 1 년 전
부모
커밋
75e374bb69
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6 0
      vrobbler/apps/scrobbles/utils.py

+ 6 - 0
vrobbler/apps/scrobbles/utils.py

@@ -92,6 +92,12 @@ def check_scrobble_for_finish(
     scrobble: "Scrobble", force_to_100=False, force_finish=False
 ) -> None:
     completion_percent = scrobble.media_obj.COMPLETION_PERCENT
+    if scrobble.media_type == "GeoLocation":
+        logger.info(
+            f"{scrobble.id} not complete, GeoLocs are completed when new one is created"
+        )
+        return
+
     if scrobble.percent_played >= completion_percent or force_finish:
         logger.info(f"{scrobble.id} finished at {scrobble.percent_played}")
         scrobble.playback_position_seconds = (