Skip to content

Commit

Permalink
Merge 622ccc8 into 6efc978
Browse files Browse the repository at this point in the history
  • Loading branch information
markedwards committed Nov 13, 2022
2 parents 6efc978 + 622ccc8 commit b31bc29
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion aiodataloader.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,11 @@ def __init__(
if cache is not None:
self.cache = cache

self.get_cache_key = get_cache_key or (lambda x: x)
if get_cache_key:
self.get_cache_key = get_cache_key

if not hasattr(self, 'get_cache_key'):
self.get_cache_key = lambda x: x

self._cache = cache_map if cache_map is not None else {}
self._queue: List[Loader] = []
Expand Down

0 comments on commit b31bc29

Please sign in to comment.