From 10f872bb3540d947f8c19803093e40e5a5243445 Mon Sep 17 00:00:00 2001 From: Julien Calixte Date: Sat, 4 Jul 2020 00:48:32 +0200 Subject: [PATCH] :recycle: (notification) typing --- src/utils/notification.ts | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/src/utils/notification.ts b/src/utils/notification.ts index c8b316d..c85437b 100644 --- a/src/utils/notification.ts +++ b/src/utils/notification.ts @@ -1,28 +1,19 @@ declare const Notification: any let showNotification: - | (( - title: string, - options?: NotificationOptions | undefined - ) => Promise) + | ((title: string, options?: NotificationOptions) => Promise) | null = null export const setNotificationInstance = ( - sn: ( - title: string, - options?: NotificationOptions | undefined - ) => Promise + sn: (title: string, options?: NotificationOptions) => Promise ) => { showNotification = sn } -export const notify = ( - title: string, - options?: NotificationOptions | undefined -) => { +export const notify = (title: string, options?: NotificationOptions) => { const showCustomNotification = ( title: string, - options?: NotificationOptions | undefined + options?: NotificationOptions ) => { if (!showNotification) { return