From 8bfa7fc8325f8a6dc55a7dd6607cb528cb67683d Mon Sep 17 00:00:00 2001 From: Karmanyaah Malhotra Date: Wed, 28 Oct 2020 11:16:54 -0400 Subject: [PATCH] Add directory check --- main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index b9bd7a9..ae71b0e 100644 --- a/main.py +++ b/main.py @@ -8,7 +8,9 @@ domain = "push.example.com" token = "z2Uny92TZBzsukg" home = os.path.expanduser('~') -path = "{}/.cache/gotify-dust".format(home) +path = "{}/.cache/gotify-dunst".format(home) +if not os.path.isdir(path): + os.mkdir(path) def get_picture(appid): imgPath = "{}/{}.jpg".format(path, appid)