Ensure content cache key does not contain path separators

This commit is contained in:
Ivan Kravets
2019-11-12 23:48:39 +02:00
parent 6e9429dbbf
commit 15f142fc70

View File

@ -199,6 +199,7 @@ class ContentCache(object):
return True
def get_cache_path(self, key):
assert "/" not in key and "\\" not in key
key = str(key)
assert len(key) > 3
return join(self.cache_dir, key[-2:], key)