Skip to content

Commit

Permalink
fix: Fix caching incorrect data
Browse files Browse the repository at this point in the history
  • Loading branch information
seriaati committed Feb 1, 2024
1 parent 550e2a2 commit afadf8f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion enka/client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import copy
import logging
from typing import TYPE_CHECKING, Any, Final

Expand Down Expand Up @@ -80,7 +81,7 @@ async def _request(self, url: str) -> dict[str, Any]:
raise_for_retcode(resp.status)

data: dict[str, Any] = await resp.json()
self._cache[url] = data
self._cache[url] = copy.deepcopy(data)
return data

def _post_process_showcase_player(self, player: "Player") -> "Player":
Expand Down

0 comments on commit afadf8f

Please sign in to comment.