From c022a29fabc562c8e075d5ec2ed5983ffb8cd48c Mon Sep 17 00:00:00 2001 From: Simon Legner Date: Sat, 6 Jan 2024 15:46:27 +0100 Subject: [PATCH] Sanity-check decaffeinate app.UpdateChecker --- assets/javascripts/app/update_checker.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/assets/javascripts/app/update_checker.js b/assets/javascripts/app/update_checker.js index 03d726ed..82d3cc92 100644 --- a/assets/javascripts/app/update_checker.js +++ b/assets/javascripts/app/update_checker.js @@ -1,16 +1,9 @@ -// TODO: This file was created by bulk-decaffeinate. -// Sanity-check the conversion and remove this comment. -/* - * decaffeinate suggestions: - * DS207: Consider shorter variations of null checks - * Full docs: https://github.com/decaffeinate/decaffeinate/blob/main/docs/suggestions.md - */ app.UpdateChecker = class UpdateChecker { constructor() { this.lastCheck = Date.now(); $.on(window, "focus", () => this.onFocus()); - if (app.serviceWorker != null) { + if (app.serviceWorker) { app.serviceWorker.on("updateready", () => this.onUpdateReady()); }