Fix: check /favicon.ico size

This commit is contained in:
Anton Gunov
2017-11-09 20:57:33 +07:00
parent 86d3476db2
commit 84dfd3b60b
3 changed files with 7 additions and 6 deletions

View File

@@ -11,6 +11,8 @@ module.exports = ($, done) => {
// ignore errors
if (err) return done(null, []);
if (res.statusCode !== 200) return done(null, []);
// check image size
if (!(parseInt(res.headers['content-length'], 10) > 0)) return done(null, []);
return done(null, [{
src: url,

View File

@@ -1,9 +1,4 @@
{
"domain": "s7.com",
"icons": [
{
"src": "http://s7.com/favicon.ico",
"type": "image/x-icon"
}
]
"icons": []
}

View File

@@ -0,0 +1,4 @@
{
"domain": "timeclockwizard.com",
"icons": []
}