From 5378970187a980a1c5197b96b4fc67730b507e74 Mon Sep 17 00:00:00 2001 From: j Date: Thu, 31 Aug 2017 15:49:19 +0200 Subject: [PATCH] use ox.makedirs --- ox/cache.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ox/cache.py b/ox/cache.py index f55ba8e..c475322 100644 --- a/ox/cache.py +++ b/ox/cache.py @@ -141,7 +141,7 @@ def save_url(url, filename, overwrite=False): if not os.path.exists(filename) or overwrite: dirname = os.path.dirname(filename) if dirname and not os.path.exists(dirname): - os.makedirs(dirname) + makedirs(dirname) data = read_url(url) with open(filename, 'wb') as f: f.write(data) @@ -178,7 +178,7 @@ class SQLiteCache(Cache): def __init__(self): path = cache_path() if not os.path.exists(path): - os.makedirs(path) + makedirs(path) self.db = os.path.join(path, "cache.sqlite") self.create()