diff --git a/src/lib/components/layout/Sidebar.svelte b/src/lib/components/layout/Sidebar.svelte index 74b349c21..c925a9589 100644 --- a/src/lib/components/layout/Sidebar.svelte +++ b/src/lib/components/layout/Sidebar.svelte @@ -49,7 +49,6 @@ import Spinner from '../common/Spinner.svelte'; import Loader from '../common/Loader.svelte'; import AddFilesPlaceholder from '../AddFilesPlaceholder.svelte'; - import SearchInput from './Sidebar/SearchInput.svelte'; import Folder from '../common/Folder.svelte'; import Plus from '../icons/Plus.svelte'; import Tooltip from '../common/Tooltip.svelte'; @@ -65,8 +64,6 @@ const BREAKPOINT = 768; let navElement; - let search = ''; - let shiftKey = false; let selectedChatId = null; @@ -177,11 +174,7 @@ currentChatPage.set(1); allChatsLoaded = false; - if (search) { - await chats.set(await getChatListBySearchText(localStorage.token, search, $currentChatPage)); - } else { - await chats.set(await getChatList(localStorage.token, $currentChatPage)); - } + await chats.set(await getChatList(localStorage.token, $currentChatPage)); // Enable pagination scrollPaginationEnabled.set(true); @@ -194,11 +187,7 @@ let newChatList = []; - if (search) { - newChatList = await getChatListBySearchText(localStorage.token, search, $currentChatPage); - } else { - newChatList = await getChatList(localStorage.token, $currentChatPage); - } + newChatList = await getChatList(localStorage.token, $currentChatPage); // once the bottom of the list has been reached (no results) there is no need to continue querying allChatsLoaded = newChatList.length === 0; @@ -632,7 +621,7 @@