mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Replace deprecated getItemImageUrl with imageUrlsApi.getItemImageUrlById
This commit is contained in:
parent
876fbee53e
commit
ed46ee5254
4 changed files with 28 additions and 31 deletions
|
@ -1,5 +1,6 @@
|
|||
import { Api } from '@jellyfin/sdk';
|
||||
import { BaseItemKind, ImageType } from '@jellyfin/sdk/lib/generated-client';
|
||||
import { getImageApi } from '@jellyfin/sdk/lib/utils/api/image-api';
|
||||
import globalize from 'scripts/globalize';
|
||||
|
||||
import type { ItemDto } from 'types/itemDto';
|
||||
|
@ -110,7 +111,7 @@ export function getImageUrl(
|
|||
}
|
||||
|
||||
if (api && imgTag && imgType && itemId) {
|
||||
const response = api.getItemImageUrl(itemId, imgType, {
|
||||
const response = getImageApi(api).getItemImageUrlById(itemId, imgType, {
|
||||
fillWidth: fillWidth,
|
||||
fillHeight: fillHeight,
|
||||
tag: imgTag
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue