Fix reference to the debug config option
... so that debug logs are enabled in some sub modules as intended. Change-Id: If3b7eb60bdcaea13de6b65241605d1e31976b309
This commit is contained in:
parent
6852d562d9
commit
6b29d8d621
|
@ -52,7 +52,7 @@ from manila.i18n import _
|
|||
|
||||
CONF = cfg.CONF
|
||||
LOG = log.getLogger(__name__)
|
||||
if hasattr('CONF', 'debug') and CONF.debug:
|
||||
if getattr(CONF, 'debug', False):
|
||||
logging.getLogger("paramiko").setLevel(logging.DEBUG)
|
||||
|
||||
_ISO8601_TIME_FORMAT_SUBSECOND = '%Y-%m-%dT%H:%M:%S.%f'
|
||||
|
@ -95,7 +95,7 @@ def execute(*cmd, **kwargs):
|
|||
"""Convenience wrapper around oslo's execute() function."""
|
||||
if 'run_as_root' in kwargs and 'root_helper' not in kwargs:
|
||||
kwargs['root_helper'] = _get_root_helper()
|
||||
if hasattr('CONF', 'debug') and CONF.debug:
|
||||
if getattr(CONF, 'debug', False):
|
||||
kwargs['loglevel'] = logging.DEBUG
|
||||
return processutils.execute(*cmd, **kwargs)
|
||||
|
||||
|
|
Loading…
Reference in New Issue