Fix bug HTTPS detection (issue with IIS)

This commit is contained in:
Frédéric Guillot
2014-09-08 16:49:54 +02:00
parent 532ea3b868
commit bc0fa40b24
5 changed files with 29 additions and 5 deletions

View File

@@ -246,7 +246,7 @@ class Response
*/
public function hsts()
{
if (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') {
if (Tool::isHTTPS()) {
header('Strict-Transport-Security: max-age=31536000');
}
}