From 481ae6e4674f77a90ad37de53c0bcd77bb51f8d0 Mon Sep 17 00:00:00 2001 From: mdwalters Date: Sun, 10 Sep 2023 00:29:53 -0400 Subject: [PATCH] fix: what was i on --- meson.build | 2 -- src/main.py | 10 +++++++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/meson.build b/meson.build index 0b95b9e..ba32c1f 100644 --- a/meson.build +++ b/meson.build @@ -7,8 +7,6 @@ project('lemonade', i18n = import('i18n') gnome = import('gnome') - - subdir('data') subdir('src') subdir('po') diff --git a/src/main.py b/src/main.py index a2bf2f4..6f92f59 100644 --- a/src/main.py +++ b/src/main.py @@ -127,8 +127,8 @@ class LemonadeWindow(Gtk.ApplicationWindow): try: print(f"Downloading icon for {community['community']['title']}") name = community["community"]["icon"].split("/")[-1] - urllib.request.urlretrieve(community["community"]["icon"], f"{os.environ['XDG_RUNTIME_DIR']}/app/{os.environ['FLATPAK_ID']}/cache/{name}") - avatar.set_custom_image(Gdk.Texture.new_from_file(Gio.File.new_for_path(f"{os.environ['XDG_RUNTIME_DIR']}/app/{os.environ['FLATPAK_ID']}/cache/{name}"))) + urllib.request.urlretrieve(community["community"]["icon"], f"{os.environ['XDG_RUNTIME_DIR']}/app/ml.mdwalters.Lemonade/cache/{name}") + avatar.set_custom_image(Gdk.Texture.new_from_file(Gio.File.new_for_path(f"{os.environ['XDG_RUNTIME_DIR']}/app/ml.mdwalters.Lemonade/cache/{name}"))) print(f"Successfully downloaded icon for {community['community']['title']}") except: print(f"Error getting icon for {community['community']['title']}") @@ -140,7 +140,11 @@ class LemonadeWindow(Gtk.ApplicationWindow): if not "description" in community["community"]: label.set_markup(f"""{community["community"]["title"]} !{community["community"]["name"]}@{community["community"]["actor_id"].split("/")[2]}""") else: - split = community["community"]["description"].split("\n")[0].replace("&", "&").replace("<", "&what;").replace(">", "&what;") + split = community["community"]["description"] + .split("\n")[0] + .replace("&", "&") + .replace("<", "&what;") + .replace(">", "&what;") label.set_markup(f"""{community["community"]["title"]} !{community["community"]["name"]}@{community["community"]["actor_id"].split("/")[2]} {split}""")