From e0c94e0f72e45e25c486e1890d811cc5e8aeb047 Mon Sep 17 00:00:00 2001 From: Andrew Aitken-Fincham Date: Thu, 15 Dec 2016 11:10:47 +0000 Subject: [PATCH] remove FRAMEWORK_PATH and namespace IPUtils --- core/Constants.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/Constants.php b/core/Constants.php index 61ff1f26e..e0537eda5 100644 --- a/core/Constants.php +++ b/core/Constants.php @@ -106,9 +106,9 @@ if(!defined('TRUSTED_PROXY')) { $trusted = true; } elseif(isset($_SERVER['REMOTE_ADDR'])) { if(!class_exists('SilverStripe\\Control\\Util\\IPUtils')) { - require_once FRAMEWORK_PATH . '/control/IPUtils.php'; + require_once 'control/IPUtils.php'; }; - $trusted = IPUtils::checkIP($_SERVER['REMOTE_ADDR'], explode(',', SS_TRUSTED_PROXY_IPS)); + $trusted = SilverStripe\Control\Util\IPUtils::checkIP($_SERVER['REMOTE_ADDR'], explode(',', SS_TRUSTED_PROXY_IPS)); } } }