获取favicon的换一下顺序

This commit is contained in:
luchenqun 2017-03-09 20:38:55 +08:00
parent 5e07109055
commit a9a21b1bd2
1 changed files with 3 additions and 3 deletions

View File

@ -960,11 +960,11 @@ api.getFaviconByTimer = function() {
});
} else {
// http://www.cnblogs.com/zhangwei595806165/p/4984912.html 各种方法都试一遍
var faviconUrl = "http://g.soz.im/" + url; // 默认地址
var faviconUrl = "http://www.google.com/s2/favicons?domain=" + url; // 默认地址
if (faviconState == 1) {
faviconUrl = "http://www.google.com/s2/favicons?domain=" + url;
} else if (faviconState == 2) {
faviconUrl = "http://favicon.byi.pw/?url=" + url;
} else if (faviconState == 2) {
faviconUrl = "http://g.soz.im/" + url;
}
download(faviconUrl).then(data => {
fs.writeFileSync(faviconPath, data);