From 26a9dba22236bc22a7612107630282cfe02d20e0 Mon Sep 17 00:00:00 2001 From: Markus Hatvan Date: Mon, 16 Aug 2021 18:10:23 +0200 Subject: chore: update outdated node_modules (#1807) - upgrade 'uuid', '@types/uuid', 'macos-version', 'normalize-url' and 'os-name' dependencies to latest - updated 'macos-version' imports to named imports --- src/webview/notifications.js | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'src/webview') diff --git a/src/webview/notifications.js b/src/webview/notifications.js index 205a3220c..73cdb89d4 100644 --- a/src/webview/notifications.js +++ b/src/webview/notifications.js @@ -1,22 +1,25 @@ import { ipcRenderer } from 'electron'; -import uuidV1 from 'uuid/v1'; +import { v1 as uuidV1 } from 'uuid'; const debug = require('debug')('Ferdi:Notifications'); export class NotificationsHandler { - onNotify = (data) => data; + onNotify = data => data; displayNotification(title, options) { - return new Promise((resolve) => { + return new Promise(resolve => { debug('New notification', title, options); const notificationId = uuidV1(); - ipcRenderer.sendToHost('notification', this.onNotify({ - title, - options, - notificationId, - })); + ipcRenderer.sendToHost( + 'notification', + this.onNotify({ + title, + options, + notificationId, + }), + ); ipcRenderer.once(`notification-onclick:${notificationId}`, () => { resolve(); -- cgit v1.2.3-54-g00ecf