diff --git a/ox/net.py b/ox/net.py index 1fd4d87..696cabb 100644 --- a/ox/net.py +++ b/ox/net.py @@ -113,7 +113,8 @@ get_url = read_url def save_url(url, filename, overwrite=False): if not os.path.exists(filename) or overwrite: dirname = os.path.dirname(filename) - os.makedirs(dirname, exist_ok=True) + if dirname: + os.makedirs(dirname, exist_ok=True) headers = DEFAULT_HEADERS.copy() r = requests.get(url, headers=headers, stream=True) filename_tmp = filename + '~'