File tree 1 file changed +5
-2
lines changed
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -326,13 +326,15 @@ async function fetchTimeMap (uri, tabid) {
326
326
setTimemapInStorage ( data , data . original )
327
327
} )
328
328
. catch ( function ( err ) {
329
- console . log ( `Error fetching {uri}` )
329
+ console . log ( `Error fetching $ {uri } ` )
330
330
console . log ( err . message )
331
331
332
332
if ( err . name === 'ZeroMementos' ) {
333
333
showInterfaceForZeroMementos ( tabid )
334
334
} else if ( err . name === 'InaccessibleAggregator' ) {
335
- log ( 'TODO: swtich up the aggregator' )
335
+ log ( 'TODO: switch up the aggregator' )
336
+ } else if ( err instanceof SyntaxError ) {
337
+ log ( "JSON parsing failed, switch up the aggregator" )
336
338
}
337
339
} )
338
340
/*
@@ -521,6 +523,7 @@ chrome.webRequest.onHeadersReceived.addListener(function (deets) {
521
523
if ( cachedTMKeys . length > 10 ) { // Keep the cache to a reasonable size through random deletion
522
524
log ( '******* Number of cached URL Headers:' )
523
525
const indexToRemove = Math . floor ( Math . random ( ) * cachedTMKeys . length )
526
+ console . log ( 'foo' )
524
527
const keyOfIndex = cachedTMKeys [ indexToRemove ]
525
528
delete data [ keyOfIndex ]
526
529
}
You can’t perform that action at this time.
0 commit comments