From 4df3079d6eb07bcda0a183c50ca15670d495e173 Mon Sep 17 00:00:00 2001 From: mdwalters Date: Sun, 2 Jul 2023 13:47:53 -0400 Subject: [PATCH] fix: use tmp for storing community icons --- src/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.py b/src/main.py index a479574..1e46427 100644 --- a/src/main.py +++ b/src/main.py @@ -84,8 +84,8 @@ class LemonadeWindow(Gtk.ApplicationWindow): if "icon" in community["community"]: try: name = community["community"]["name"] - urllib.request.urlretrieve(community["community"]["icon"], f"{name}.png") - avatar.set_custom_image(Gdk.Texture.new_from_file(Gio.File.new_for_path(f"./{name}.png"))) + urllib.request.urlretrieve(community["community"]["icon"], f"/tmp/{name}.png") + avatar.set_custom_image(Gdk.Texture.new_from_file(Gio.File.new_for_path(f"/tmp/{name}.png"))) except urllib.error.HTTPError as e: print(f"Error while downloading icon: {e}") pass