• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mozilla / blurts-server / #13322

pending completion
#13322

push

circleci

web-flow
Merge pull request #3001 from mozilla/main

Merge `main` into `localization`

282 of 1768 branches covered (15.95%)

Branch coverage included in aggregate %.

451 of 451 new or added lines in 56 files covered. (100.0%)

959 of 4670 relevant lines covered (20.54%)

1.72 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/client/js/partials/notFound.js
1
/* This Source Code Form is subject to the terms of the Mozilla Public
2
 * License, v. 2.0. If a copy of the MPL was not distributed with this
3
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4

5
if (window.history.length > 1) {
×
6
  const backCta = document.getElementById('back-cta')
×
7
  backCta?.addEventListener('click', () => {
×
8
    window.history.back()
×
9

10
    window.gtag('event', 'clicked_go_back', { action: 'click', page_location: location.href })
×
11

12
    // The call to `window.history.back()` might do nothing; for example, if the
13
    // user has clicked Back to get to the 404 page: while there might not be
14
    // another page to go back to, window.history.length will still be > 1
15
    // because of the page the user can go forward to.
16
    // Unfortunately there's no way to check whether it's possible to go back,
17
    // or to check whether `.back()` succeeded, so we just use the fallback
18
    // after half a second as passed:
19
    setTimeout(() => {
×
20
      document.location = '/'
×
21
    }, 500)
22
  })
23
  document.getElementById('home-cta')?.toggleAttribute('hidden', true)
×
24
  backCta?.toggleAttribute('hidden', false)
×
25
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc