Skip to content

Commit

Permalink
Wrapped negative AND to double negative OR
Browse files Browse the repository at this point in the history
For readability and easier understanding.
  • Loading branch information
sisou committed Sep 9, 2024
1 parent 5f0f702 commit d4101cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ async function runKeyguard(RequestApiClass, opts) { // eslint-disable-line no-un

// Back arrow functionality
document.body.addEventListener('click', event => {
if (!(event.target instanceof HTMLElement && event.target.matches('a.page-header-back-button'))) return;
if (!(event.target instanceof HTMLElement) || !event.target.matches('a.page-header-back-button')) return;
window.history.back();
});

Expand Down

0 comments on commit d4101cb

Please sign in to comment.