diff options
| author | 2016-04-23 22:03:03 +0200 | |
|---|---|---|
| committer | 2016-04-23 22:03:03 +0200 | |
| commit | be4f588911c5ef4ad2108154fea0433a90b6e791 (patch) | |
| tree | 66c6ed1d8960f828e815b1502038e5445ea0ac63 /lib | |
| parent | 70c842031f01422c29fb179610aaf856d92e807c (diff) | |
| parent | 624824673592dbc21300f9a26c27781f54429de5 (diff) | |
Merge branch 'favicon_bug' into dev
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/Favicon/DataAccess.php | 3 | ||||
| -rw-r--r-- | lib/Favicon/Favicon.php | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/Favicon/DataAccess.php b/lib/Favicon/DataAccess.php index 2bfdf640e..17f26b333 100644 --- a/lib/Favicon/DataAccess.php +++ b/lib/Favicon/DataAccess.php @@ -15,7 +15,8 @@ class DataAccess { public function retrieveHeader($url) { $this->set_context(); - return @get_headers($url, TRUE); + $headers = @get_headers($url, 1); + return array_change_key_case($headers); } public function saveCache($file, $data) { diff --git a/lib/Favicon/Favicon.php b/lib/Favicon/Favicon.php index 7ea6ccf16..1912050d6 100644 --- a/lib/Favicon/Favicon.php +++ b/lib/Favicon/Favicon.php @@ -99,7 +99,7 @@ class Favicon switch ($status) { case '301': case '302': - $url = $headers['Location']; + $url = isset($headers['location']) ? $headers['location'] : ''; break; default: $loop = FALSE; |
