mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Fix undefined server id in experimental layout
This commit is contained in:
parent
c11fe56d65
commit
29551e49bf
6 changed files with 29 additions and 8 deletions
|
@ -5,6 +5,8 @@ import { ItemSortBy } from '@jellyfin/sdk/lib/generated-client/models/item-sort-
|
|||
import React, { type FC, useCallback } from 'react';
|
||||
import Box from '@mui/material/Box';
|
||||
import classNames from 'classnames';
|
||||
|
||||
import { useApi } from 'hooks/useApi';
|
||||
import { useLocalStorage } from 'hooks/useLocalStorage';
|
||||
import { useGetItemsViewByType } from 'hooks/useFetchItems';
|
||||
import { getDefaultLibraryViewSettings, getSettingsKey } from 'utils/items';
|
||||
|
@ -69,6 +71,7 @@ const ItemsView: FC<ItemsViewProps> = ({
|
|||
getDefaultLibraryViewSettings(viewType)
|
||||
);
|
||||
|
||||
const { __legacyApiClient__ } = useApi();
|
||||
const {
|
||||
isLoading,
|
||||
data: itemsResult,
|
||||
|
@ -138,7 +141,8 @@ const ItemsView: FC<ItemsViewProps> = ({
|
|||
preferLogo: preferLogo,
|
||||
overlayText: !libraryViewSettings.ShowTitle,
|
||||
imageType: libraryViewSettings.ImageType,
|
||||
queryKey: ['ItemsViewByType']
|
||||
queryKey: ['ItemsViewByType'],
|
||||
serverId: __legacyApiClient__?.serverId()
|
||||
};
|
||||
|
||||
if (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue