Silent error

1.10.x
jmontoya 9 years ago
parent 6ca9a4f9bd
commit 891d518eec
  1. 2
      main/inc/lib/api.lib.php

@ -6775,7 +6775,7 @@ function api_get_real_ip(){
$ip = trim($_SERVER['REMOTE_ADDR']);
if (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
if (preg_match('/,/', $_SERVER['HTTP_X_FORWARDED_FOR'])) {
list($ip1, $ip2) = explode(',', $_SERVER['HTTP_X_FORWARDED_FOR']);
@list($ip1, $ip2) = @explode(',', $_SERVER['HTTP_X_FORWARDED_FOR']);
} else {
$ip1 = $_SERVER['HTTP_X_FORWARDED_FOR'];
}

Loading…
Cancel
Save