chrome.storage.sync.get(['subscribedForems','allforems'],function(result){constmyForems=result.subscribedForems;constallForems=result.allforems;if(!myForems){chrome.storage.sync.set({subscribedForems:[]});// Create empty array if not initialized.}if(!allForems){chrome.storage.sync.set({allforems:[]});// Create empty array if not initialized.}// myOrigins(null) will break map on line 203if(myOrigins(myForems).includes(currentOrigin)||validOrigins(allForems).includes(currentOrigin)||currentOrigin==='https://www.forem.com'){loadForemHTML(result.subscribedForems);document.addEventListener('add',handleAdd,false);document.addEventListener('remove',handleRemove,false);document.addEventListener('reorder',handleReorder,false);}
This would remove the error though I've not thought the logic through yet
chrome.storage.sync.get(['subscribedForems','allforems'],function(result){constmyForems=result.subscribedForems?result.subscribedForems:[];constallForems=result.allforems?result.allforems:[];if(!result.subscribedForems){chrome.storage.sync.set({subscribedForems:[]});// Create empty array if not initialized.}if(!result.allforems){chrome.storage.sync.set({allforems:[]});// Create empty array if not initialized.}if(myOrigins(myForems).includes(currentOrigin)||validOrigins(allForems).includes(currentOrigin)||currentOrigin==='https://www.forem.com'){loadForemHTML(result.subscribedForems);document.addEventListener('add',handleAdd,false);document.addEventListener('remove',handleRemove,false);document.addEventListener('reorder',handleReorder,false);}
For further actions, you may consider blocking this person and/or reporting abuse
I think I see it
This would remove the error though I've not thought the logic through yet
Another fix.