/** * Work around non-transparent proxy and reverse proxy IP issues * * @return void */ protected function workaroundIP() { $enableWorkarounds = $this->componentParams->getValue('ipworkarounds', -1); // Upgrade from older versions (default: enable IP workarounds) if ($enableWorkarounds == -1) { $enableWorkarounds = 1; $this->componentParams->setValue('ipworkarounds', 1, true); } if (class_exists('F0FUtilsIp', true)) { F0FUtilsIp::setAllowIpOverrides($enableWorkarounds); F0FUtilsIp::workaroundIPIssues(); } }
/** * Work around non-transparent proxy and reverse proxy IP issues * * @return void */ protected function workaroundIP() { // IP workarounds are always disabled in the Core version if (!defined('ADMINTOOLS_PRO')) { require_once JPATH_ADMINISTRATOR . '/components/com_admintools/version.php'; } if (!ADMINTOOLS_PRO) { return; } $enableWorkarounds = $this->componentParams->getValue('ipworkarounds', -1); // Upgrade from older versions (default: enable IP workarounds) if ($enableWorkarounds == -1) { $enableWorkarounds = 1; $this->componentParams->setValue('ipworkarounds', 1, true); } if (class_exists('F0FUtilsIp', true)) { F0FUtilsIp::setAllowIpOverrides($enableWorkarounds); F0FUtilsIp::workaroundIPIssues(); } }