From 3c944fa2dd40f544568e6709bf0a8e13bda7e783 Mon Sep 17 00:00:00 2001 From: Dafnik Date: Fri, 29 Dec 2023 17:18:24 +0100 Subject: [PATCH] fix(dfts-helper): strip whitespace --- libs/dfts-helper/src/lib/helper/string/strip-whitespace.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/dfts-helper/src/lib/helper/string/strip-whitespace.ts b/libs/dfts-helper/src/lib/helper/string/strip-whitespace.ts index 6551fb44..b0db1f75 100644 --- a/libs/dfts-helper/src/lib/helper/string/strip-whitespace.ts +++ b/libs/dfts-helper/src/lib/helper/string/strip-whitespace.ts @@ -1,3 +1,3 @@ import { UndefinedOrNullOr } from '../../types'; -export const s_stripWhitespace = (text: UndefinedOrNullOr): string => text?.trim().replace(/^\s+/, '').replace(/\s+$/, '') ?? ''; +export const s_stripWhitespace = (text: UndefinedOrNullOr): string => text?.trim().replace(/\s/g, '') ?? '';