diff --git a/src/js/assets.js b/src/js/assets.js index 07255364f..d0db48449 100644 --- a/src/js/assets.js +++ b/src/js/assets.js @@ -1011,7 +1011,9 @@ var updateDone = function() { api.updateStart = function(details) { var oldUpdateDelay = updaterAssetDelay, - newUpdateDelay = details.delay || updaterAssetDelayDefault; + newUpdateDelay = typeof details.delay === 'number' ? + details.delay : + updaterAssetDelayDefault; updaterAssetDelay = Math.min(oldUpdateDelay, newUpdateDelay); if ( updaterStatus !== undefined ) { if ( newUpdateDelay < oldUpdateDelay ) { diff --git a/src/js/messaging.js b/src/js/messaging.js index 51c91606c..eefb95788 100644 --- a/src/js/messaging.js +++ b/src/js/messaging.js @@ -121,7 +121,9 @@ var onMessage = function(request, sender, callback) { case 'forceUpdateAssets': µb.scheduleAssetUpdater(0); - µb.assets.updateStart({ delay: µb.hiddenSettings.manualUpdateAssetFetchPeriod || 2000 }); + µb.assets.updateStart({ + delay: µb.hiddenSettings.manualUpdateAssetFetchPeriod + }); break; case 'getAppData':