fix(search): error when not selected

This commit is contained in:
三咲智子 2023-01-08 15:57:21 +08:00
parent b30ebc12f8
commit 4ca2053bb2
No known key found for this signature in database
GPG key ID: 69992F2250DFD93E
2 changed files with 6 additions and 6 deletions

View file

@ -57,9 +57,7 @@ export function useSearch(query: MaybeRef<string>, options?: UseSearchOptions) {
}
watch(() => unref(query), () => {
if (!unref(query) || !isMastoInitialised.value)
return
loading.value = true
loading.value = !!(unref(query) && isMastoInitialised.value)
})
debouncedWatch(() => unref(query), async () => {