Skip to content

Commit

Permalink
Fix wrong operator precedence: negation vs 'in'
Browse files Browse the repository at this point in the history
  • Loading branch information
sj authored Dec 12, 2018
1 parent 807e8ad commit c2864b0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions demos/network-idle.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ navigator.serviceWorker.getRegistration()
function networkIdleCallback(fn, options = {timeout: 0}) {
// Call the function immediately if required features are absent
if (
!'MessageChannel' in window ||
!'serviceWorker' in navigator ||
!('MessageChannel' in window) ||
!('serviceWorker' in navigator) ||
!navigator.serviceWorker.controller
) {
DOMContentLoad.then(() => fn({didTimeout: false}));
Expand Down

0 comments on commit c2864b0

Please sign in to comment.