[HttpFoundation] Fixed isSecure() check to be compliant with the docs

This commit is contained in:
Jannik Zschiesche 2014-05-23 19:00:00 +02:00 committed by Fabien Potencier
parent eca7915a1e
commit 7bc37bd899

View File

@ -1100,7 +1100,9 @@ class Request
return in_array(strtolower(current(explode(',', $proto))), array('https', 'on', 'ssl', '1'));
}
return 'on' == strtolower($this->server->get('HTTPS')) || 1 == $this->server->get('HTTPS');
$https = $this->server->get('HTTPS');
return !empty($https) && 'off' !== strtolower($https);
}
/**