1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

Fix bug with initial keystroke resulting in empty search

This commit is contained in:
viown 2025-03-06 13:29:17 +03:00
parent ad01e8669d
commit d9aa7319be
3 changed files with 9 additions and 14 deletions

View file

@ -9,7 +9,7 @@ import { MediaType } from '@jellyfin/sdk/lib/generated-client/models/media-type'
import { BaseItemKind } from '@jellyfin/sdk/lib/generated-client/models/base-item-kind';
import { ItemsApiGetItemsRequest } from '@jellyfin/sdk/lib/generated-client/api/items-api';
const fetchPeople = async (
const fetchVideos = async (
api: Api,
userId: string,
params?: ItemsApiGetItemsRequest,
@ -43,7 +43,7 @@ export const useVideoSearch = (
return useQuery({
queryKey: ['VideoSearch', collectionType, parentId, searchTerm],
queryFn: ({ signal }) => fetchPeople(
queryFn: ({ signal }) => fetchVideos(
api!,
userId!,
{