Skip to content

Commit

Permalink
Couple missed points.
Browse files Browse the repository at this point in the history
  • Loading branch information
ThePhar committed Apr 12, 2024
1 parent c7da309 commit 1652b3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
1 change: 1 addition & 0 deletions WebHostLib/templates/tracker__ALinkToThePast.html
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@

const fakeDOM = parser.parseFromString(await response.text(), "text/html");
document.querySelector(".inventory-grid").innerHTML = fakeDOM.querySelector(".inventory-grid").innerHTML;
document.querySelector(".regions-list").innerHTML = fakeDOM.querySelector(".regions-list").innerHTML;
}
</script>
</body>
Expand Down
7 changes: 3 additions & 4 deletions WebHostLib/tracker.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,10 +295,9 @@ def get_room_videos(self) -> Dict[TeamPlayer, Tuple[str, str]]:
@app.route("/tracker/<suuid:tracker>/<int:tracked_team>/<int:tracked_player>")
def get_player_tracker(tracker: UUID, tracked_team: int, tracked_player: int, generic: bool = False) -> str:
key = f"{tracker}_{tracked_team}_{tracked_player}_{generic}"
# TODO: Remove this debug to bypass cache.
# tracker_page = cache.get(key)
# if tracker_page:
# return tracker_page
tracker_page = cache.get(key)
if tracker_page:
return tracker_page

timeout, tracker_page = get_timeout_and_tracker(tracker, tracked_team, tracked_player, generic)
cache.set(key, tracker_page, timeout)
Expand Down

0 comments on commit 1652b3c

Please sign in to comment.