From 1198bf62bbbefa545745e42d77fb5909304163f9 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..b24bd4713 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); } };