From: Jérôme Benoit Date: Mon, 11 Dec 2023 23:17:16 +0000 (+0100) Subject: refactor: fix type casting X-Git-Tag: v1.2.30~21 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=a0f6a472bec8c68962405941dade32df096b8c3a;p=e-mobility-charging-stations-simulator.git refactor: fix type casting Signed-off-by: Jérôme Benoit --- diff --git a/src/utils/Utils.ts b/src/utils/Utils.ts index d99dcc3a..366ccf98 100644 --- a/src/utils/Utils.ts +++ b/src/utils/Utils.ts @@ -79,7 +79,7 @@ export const convertToDate = ( value: Date | string | number | null | undefined, ): Date | null | undefined => { if (isNullOrUndefined(value)) { - return value as undefined; + return value as null | undefined; } if (isDate(value)) { return value;