From 632fd8c87c268b4337e521d44968891759cf4291 Mon Sep 17 00:00:00 2001 From: aleks Date: Fri, 21 Jun 2024 23:37:49 +0500 Subject: [PATCH] fix(utils): correct after tests --- frontend/src/utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/utils.ts b/frontend/src/utils.ts index d80cef9..58ecfe4 100644 --- a/frontend/src/utils.ts +++ b/frontend/src/utils.ts @@ -17,4 +17,4 @@ export const div = (a: number, b: number) => { return (a - a % b) / b; }; -export const cleanString = (s: string) => s?.trim()?.replaceAll(/\s{2,}/g, " "); \ No newline at end of file +export const cleanString = (s: string | null) => s?.trim()?.replaceAll(/\s{2,}/g, " ") ?? null; \ No newline at end of file