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

Fix spurious errors in uBO's dev console

Those spurious errors occurred when launching the browser
with the dashboard already opened from the previous
browsing session.
This commit is contained in:
Raymond Hill 2021-10-26 08:54:04 -04:00
parent c136c7b454
commit 5bea149e8f
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -118,7 +118,7 @@ if ( self.location.hash.slice(1) === 'no-dashboard.html' ) {
]);
{
const details = results[0];
const details = results[0] || {};
document.body.classList.toggle(
'canUpdateShortcuts',
details.canUpdateShortcuts === true
@ -132,7 +132,7 @@ if ( self.location.hash.slice(1) === 'no-dashboard.html' ) {
}
{
let pane = results[1];
let pane = results[1] || null;
if ( self.location.hash !== '' ) {
pane = self.location.hash.slice(1) || null;
}