create download directory if it doesn't exist
This commit is contained in:
parent
c18c1725c4
commit
7fac63a37b
2 changed files with 3 additions and 0 deletions
|
@ -21,6 +21,7 @@ at anytime.
|
||||||
### Fixed
|
### Fixed
|
||||||
* Fix restart procedure in DaemonControl
|
* Fix restart procedure in DaemonControl
|
||||||
*
|
*
|
||||||
|
* Create download directory if it doesn't exist
|
||||||
*
|
*
|
||||||
|
|
||||||
## [0.9.2rc1] - 2017-03-21
|
## [0.9.2rc1] - 2017-03-21
|
||||||
|
|
|
@ -232,6 +232,8 @@ class Daemon(AuthJSONRPCServer):
|
||||||
conf.settings.update(last_version)
|
conf.settings.update(last_version)
|
||||||
self.db_dir = conf.settings['data_dir']
|
self.db_dir = conf.settings['data_dir']
|
||||||
self.download_directory = conf.settings['download_directory']
|
self.download_directory = conf.settings['download_directory']
|
||||||
|
if not os.path.exists(self.download_directory):
|
||||||
|
os.mkdir(self.download_directory)
|
||||||
self.created_data_dir = False
|
self.created_data_dir = False
|
||||||
if not os.path.exists(self.db_dir):
|
if not os.path.exists(self.db_dir):
|
||||||
os.mkdir(self.db_dir)
|
os.mkdir(self.db_dir)
|
||||||
|
|
Loading…
Add table
Reference in a new issue