From 95b033bab0043e5281bda0c23b119cd81f720208 Mon Sep 17 00:00:00 2001 From: Frank Brehm Date: Thu, 31 Mar 2022 11:32:59 +0200 Subject: [PATCH] Fixing lib/pp_admintools/pdns_config.py --- lib/pp_admintools/pdns_config.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/lib/pp_admintools/pdns_config.py b/lib/pp_admintools/pdns_config.py index d31137f..d3e1a06 100644 --- a/lib/pp_admintools/pdns_config.py +++ b/lib/pp_admintools/pdns_config.py @@ -34,7 +34,7 @@ from .xlate import XLATOR LIBRARY_NAME = "pp-pdns-api-client" -__version__ = '0.2.1' +__version__ = '0.2.2' LOG = logging.getLogger(__name__) _ = XLATOR.gettext @@ -250,8 +250,10 @@ class PdnsConfiguration(MailConfiguration): except (ValueError, TypeError) as e: msg = _("Value {!r} for PowerDNS API timeout is invalid:").format(val) msg += " " + str(e) + if self.raise_on_error: + raise PdnsConfigError(msg) LOG.error(msg) - continue + return self.pdns_timeout = timeout @@ -319,7 +321,7 @@ class PdnsConfiguration(MailConfiguration): if val: if self.verbose > 2: key_show = '******' - self.verbose > 4: + if self.verbose > 4: key_show = val msg = _("Found API key for PDNS: {!r}.").format(key_show) LOG.debug(msg) -- 2.39.5