From 3dffdc3f0babd084318442a3ba7c6834cd12c4d6 Mon Sep 17 00:00:00 2001 From: Daniel Gasienica Date: Tue, 6 Mar 2018 12:10:35 -0500 Subject: [PATCH] Rename `Errors` to `GlobalErrors` for clarity --- js/modules/{errors.js => global_errors.js} | 4 ++-- main.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) rename js/modules/{errors.js => global_errors.js} (81%) diff --git a/js/modules/errors.js b/js/modules/global_errors.js similarity index 81% rename from js/modules/errors.js rename to js/modules/global_errors.js index 4a6bb7c3b..b868bd0a5 100644 --- a/js/modules/errors.js +++ b/js/modules/global_errors.js @@ -3,8 +3,8 @@ const addUnhandledErrorHandler = require('electron-unhandled'); const Errors = require('./types/errors'); -// addGlobalHandler :: Unit -> Unit -exports.addGlobalHandler = () => { +// addHandler :: Unit -> Unit +exports.addHandler = () => { addUnhandledErrorHandler({ logger: (error) => { console.error( diff --git a/main.js b/main.js index 4108ebccd..0ea657e45 100644 --- a/main.js +++ b/main.js @@ -18,12 +18,12 @@ const packageJson = require('./package.json'); const autoUpdate = require('./app/auto_update'); const createTrayIcon = require('./app/tray_icon'); -const Errors = require('./js/modules/errors'); +const GlobalErrors = require('./js/modules/global_errors'); const logging = require('./app/logging'); const windowState = require('./app/window_state'); const { createTemplate } = require('./app/menu'); -Errors.addGlobalHandler(); +GlobalErrors.addHandler(); const appUserModelId = `org.whispersystems.${packageJson.name}`; console.log('Set Windows Application User Model ID (AUMID)', { appUserModelId });