Got it. And upvoted.
And yes I was facing it in Firefox 62 as well.
Here’s the code I used as a workaround in my background.js
:
function loadStart(){
browser.tabs.update(
{
url: "index.html"
}
)
}
browser.runtime.onStartup.addListener(loadStart) // does not fire in private browsing, not recommended
function pushStart(data) {
if (data == null) {
loadStart()
}
else {
// console.log("tab is well defined")
}
}
var currentTab = browser.tabs.getCurrent()
currentTab.then((data)=>(pushStart(data)))