From 8d0712de5bcedcaae99fd68aaf6a8baf8e31b410 Mon Sep 17 00:00:00 2001 From: Renat Kalimulin Date: Mon, 15 Jul 2024 10:31:34 +0300 Subject: [PATCH] tsc fix --- frontend/src/lib/hooks/useMessagesFiltersFields.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/frontend/src/lib/hooks/useMessagesFiltersFields.ts b/frontend/src/lib/hooks/useMessagesFiltersFields.ts index c95fbe2fa..dfd71fd98 100644 --- a/frontend/src/lib/hooks/useMessagesFiltersFields.ts +++ b/frontend/src/lib/hooks/useMessagesFiltersFields.ts @@ -50,8 +50,9 @@ export function useMessagesFiltersFields(topicName: string) { const setTopicMessageFiltersFromLocalStorage = ( key: keyof MessagesFilterFieldsType ) => { - if (topicMessagesFilters[key]) { - params.set(MessagesFilterKeys[key], topicMessagesFilters[key]); + const value = topicMessagesFilters[key]; + if (value) { + params.set(MessagesFilterKeys[key], value); } };