1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-10-04 16:47:15 +02:00

Safari: just extra precaution

This commit is contained in:
Chris 2015-02-09 22:24:50 -07:00
parent ac6211f1af
commit 6e7f26f925

View File

@ -71,6 +71,7 @@
if(keys === null) {
for(i in this._storage) {
if(!this._storage.hasOwnProperty(i)) continue;
value = this._storage[i];
if(typeof value === 'string') {
@ -93,6 +94,7 @@
}
} else if(typeof keys === 'object') {
for(i in keys) {
if(!keys.hasOwnProperty(i)) continue;
value = this._storage[i];
if(typeof value === 'string') {
@ -197,7 +199,6 @@
}
}
}, true);
// onClosed handled in the main tab-close event
// onUpdated handled via monitoring the history.pushState on web-pages
// onPopup is handled in window.open on web-pages
@ -298,7 +299,7 @@
details.index = curWin.tabs.indexOf(curWin.activeTab) + 1;
}
tab = details.tabId && this.stack[details.tabId] || curWin.openTab(details.active ? 'foreground' : 'background');
tab = (details.tabId ? this.stack[details.tabId] : curWin.openTab(details.active ? 'foreground' : 'background'));
if(details.index !== undefined) {
curWin.insertTab(tab, details.index);