fix:logic of friends and users search

This commit is contained in:
2025-10-20 11:35:44 +02:00
parent f547ee5a84
commit 634ce8adf8
3 changed files with 39 additions and 24 deletions

View File

@@ -134,6 +134,8 @@
// Search users when query changes with debounce
let searchTimeout: ReturnType<typeof setTimeout>;
$effect(() => {
// Track searchQuery dependency explicitly
searchQuery;
clearTimeout(searchTimeout);
searchTimeout = setTimeout(searchUsers, 300);
});