fix favicon logic

This commit is contained in:
Nolan Lawson 2018-04-19 09:09:31 -07:00
parent 7f5bea8f5b
commit c384bd8fff
1 changed files with 3 additions and 3 deletions

View File

@ -8,10 +8,10 @@ export function notificationObservers (store) {
if (!process.browser) {
return
}
if (currentFaviconHasNotifications === hasNotifications) {
return
}
scheduleIdleTask(() => {
if (currentFaviconHasNotifications === hasNotifications) {
return
}
setFavicon(hasNotifications ? '/favicon-alert.png' : '/favicon.png')
currentFaviconHasNotifications = !currentFaviconHasNotifications
})