aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Taylor <user234683@users.noreply.github.com>2019-08-11 17:27:55 -0700
committerJames Taylor <user234683@users.noreply.github.com>2019-08-11 17:27:55 -0700
commit5a6c65774bf44ce4b2dadf3523a9125aa851561a (patch)
tree8af2e38e6ae16efcfa0d1fb1fab9b20e94c08651
parent42036f92d25ec8f0a94e4f3af41c0977eca1274a (diff)
downloadyt-local-5a6c65774bf44ce4b2dadf3523a9125aa851561a.tar.lz
yt-local-5a6c65774bf44ce4b2dadf3523a9125aa851561a.tar.xz
yt-local-5a6c65774bf44ce4b2dadf3523a9125aa851561a.zip
Fix bug when thumbnail directory doesn't exist where first downloaded thumbnail is made a directory
-rw-r--r--youtube/subscriptions.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/youtube/subscriptions.py b/youtube/subscriptions.py
index 3a0ef49..8937a96 100644
--- a/youtube/subscriptions.py
+++ b/youtube/subscriptions.py
@@ -553,7 +553,7 @@ def serve_subscription_thumbnail(thumbnail):
try:
f = open(thumbnail_path, 'wb')
except FileNotFoundError:
- os.makedirs(thumbnail_path, exist_ok = True)
+ os.makedirs(thumbnails_directory, exist_ok = True)
f = open(thumbnail_path, 'wb')
f.write(image)
f.close()