colors: Fix cache file name.
@@ -84,8 +84,8 @@ def get(img, cache_dir=CACHE_DIR,
color_count=COLOR_COUNT, notify=False):
"""Get the colorscheme."""
# _home_dylan_img_jpg.json
- cache_file = os.path.join(cache_dir, "schemes",
- img.replace("/", "_"), ".json")
+ cache_file = img.replace("/", "_").replace(".", "_")
+ cache_file = os.path.join(cache_dir, "schemes", cache_file + ".json")
if os.path.isfile(cache_file):
colors = util.read_file_json(cache_file)
