Fix: search opens when losing focus, prevent unnecessary search API calls (#2867)
Co-Authored-By: shamoon <4887959+shamoon@users.noreply.github.com>
This commit is contained in:
1 parent
3955743590
commit
3b76772f81
2 files changed
+52
-31
No files matched your search
@@ -120,7 +120,7 @@ export default function QuickLaunch({
|
||||
});
|
||||
|
||||
if (showSearchSuggestions && searchProvider.suggestionUrl) {
|
||||
if (searchString.trim() !== searchSuggestions[0]) {
|
||||
if (searchString.trim() !== searchSuggestions[0]?.trim()) {
|
||||
fetch(
|
||||
`/api/search/searchSuggestion?query=${encodeURIComponent(searchString)}&providerName=${
|
||||
searchProvider.name ?? "Custom"
|
||||
|
||||
Reference in new issue
Block a user