paster: fix redundant question on writable dir. The question needs to

be asked only when the dir is actually not writable.
This commit is contained in:
Marcin Kuzminski 2016-06-24 20:50:51 +02:00
parent 8667353668
commit cf352c6625

View file

@ -478,9 +478,9 @@ class DbManage(object):
elif not os.access(path, os.W_OK) and path_ok:
log.warning('No write permission to given path %s' % (path,))
q = ('Given path %s is not writeable, do you want to '
'continue with read only mode ? [y/n]' % (path,))
if not self.ask_ok(q):
q = ('Given path %s is not writeable, do you want to '
'continue with read only mode ? [y/n]' % (path,))
if not self.ask_ok(q):
log.error('Canceled by user')
sys.exit(-1)