From b9caf4a6fbd71d8842a597aa504663c39e1b7fcd Mon Sep 17 00:00:00 2001 From: Andrew Holloway Date: Fri, 3 Jan 2025 13:55:00 -0600 Subject: [PATCH] refactor(ToastNotification): simplify dismiss type evaluation --- src/components/ToastNotification/ToastNotification.tsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/ToastNotification/ToastNotification.tsx b/src/components/ToastNotification/ToastNotification.tsx index bc68a1f0f..b31341165 100644 --- a/src/components/ToastNotification/ToastNotification.tsx +++ b/src/components/ToastNotification/ToastNotification.tsx @@ -66,8 +66,7 @@ export const ToastNotification = ({ ); // if both are defined, temporarily prefer the original value of dissmissType to avoid accidental overrides - const tempDismissType = - dissmissType && dismissType ? dissmissType : dismissType; + const tempDismissType = dissmissType ?? dismissType; assertEdsUsage( [