]> git.mxchange.org Git - core.git/commitdiff
Continued:
authorRoland Häder <roland@mxchange.org>
Sat, 18 Feb 2023 00:03:09 +0000 (01:03 +0100)
committerRoland Häder <roland@mxchange.org>
Sat, 18 Feb 2023 00:03:09 +0000 (01:03 +0100)
- also turned 'quiet_resolver' into a is_*_enabled entry

framework/config-global.php
framework/main/classes/tools/console/class_ConsoleTools.php
tests/bootstrap.php

index 4ff4398936bf8a506394af99dbebb2202afce641..4c2a729dff29c8153247d859c1e2a80a28cd1568 100644 (file)
@@ -448,9 +448,6 @@ $cfg->setConfigEntry('extension_uuid_loaded', false);
 // CFG: REGISTRY-ITERATOR-CLASS
 $cfg->setConfigEntry('registry_iterator_class', 'Org\Mxchange\CoreFramework\Iterator\Registry\RegistryIterator');
 
-// CFG: QUIET-DNS-RESOLVER
-$cfg->setConfigEntry('quiet_dns_resolver', false);
-
 // CFG: THOUSANDS-SEPARATOR
 $cfg->setConfigEntry('thousands_separator', '.');
 
@@ -522,3 +519,6 @@ $cfg->setConfigEntry('is_crypt_fixed_salt_enabled', false);
 
 // CFG: IS-DB-UPDATE-PRIMARY-FORCED-ENABLED
 $cfg->setConfigEntry('is_db_update_primary_forced_enabled', true);
+
+// CFG: IS-QUIET-DNS-RESOLVER-ENABLED
+$cfg->setConfigEntry('is_quiet_dns_resolver_enabled', false);
index 5d33e69c43c3c338e4129363e2f45898c081a794..c39193ce33baf1301642eeb9df44979b341a27a4 100644 (file)
@@ -45,7 +45,7 @@ class ConsoleTools extends BaseFrameworkSystem {
        /**
         * Default is that this class is noisy
         */
-       private static $quietResolver = FALSE;
+       private static $isQuietResolver = FALSE;
 
        /**
         * Protected constructor
@@ -57,7 +57,7 @@ class ConsoleTools extends BaseFrameworkSystem {
                parent::__construct(__CLASS__);
 
                // Cache configuration entry
-               self::$quietResolver = FrameworkBootstrap::getConfigurationInstance()->getConfigEntry('quiet_dns_resolver');
+               self::$isQuietResolver = FrameworkBootstrap::getConfigurationInstance()->isEnabled('quiet_dns_resolver');
        }
 
        /**
@@ -216,7 +216,7 @@ class ConsoleTools extends BaseFrameworkSystem {
                if (empty($hostname)) {
                        // Throw IAE
                        throw new InvalidArgumentException('Parameter "hostname" is empty', FrameworkInterface::EXCEPTION_INVALID_ARGUMENT);
-               } elseif (self::$quietResolver !== TRUE) {
+               } elseif (self::$isQuietResolver !== TRUE) {
                        // Debug message
                        self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('[%s:] Host name to resolve is: %s',
                                __CLASS__,
@@ -249,7 +249,7 @@ class ConsoleTools extends BaseFrameworkSystem {
                        $ipAddress = $ipResolved;
 
                        // Quiet?
-                       if (self::$quietResolver !== TRUE) {
+                       if (self::$isQuietResolver !== TRUE) {
                                // Debug message
                                self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('[%s:] Resolved IP address is: %s',
                                        __CLASS__,
index 9e12404c9e6d614a00f90eb289df6fb9e5a42e77..bba9cad0d78f57b97d537ba2ba6cc41db9e89be1 100644 (file)
@@ -44,4 +44,4 @@ if (extension_loaded('xdebug')) {
 require dirname(__DIR__) . '/vendor/autoload.php';
 
 // Quiet DNS resolver as this is not wanted here
-FrameworkBootstrap::getConfigurationInstance()->setConfigEntry('quiet_dns_resolver', TRUE);
+FrameworkBootstrap::getConfigurationInstance()->setConfigEntry('is_quiet_dns_resolver_enabled', TRUE);