check if searchQuery (#226)

This commit is contained in:
Ilya Y 2023-09-20 16:15:34 +03:00 committed by GitHub
parent 628f9ae3b0
commit 5aa0d1c98b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -45,6 +45,7 @@ export const ProfileSubscriptionsPage = () => {
})
createEffect(() => {
console.log('!!! subscriptionFilter():', subscriptionFilter())
if (following()) {
if (subscriptionFilter() === 'users') {
setFiltered(following().filter((s) => 'name' in s))
@ -54,7 +55,9 @@ export const ProfileSubscriptionsPage = () => {
setFiltered(following())
}
}
if (searchQuery()) {
setFiltered(dummyFilter(following(), searchQuery(), lang()))
}
})
return (