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

Apply suggestion

This commit is contained in:
LJQ 2024-09-05 01:06:26 +08:00
parent e34c10644e
commit c02b1e651f

View file

@ -21,7 +21,7 @@ import ServerConnections from '../ServerConnections';
import toast from '../toast/toast';
import { appRouter } from '../router/appRouter';
import template from './metadataEditor.template.html';
import { SeriesStatus } from '@jellyfin/sdk/lib/generated-client';
import { BaseItemKind, SeriesStatus } from '@jellyfin/sdk/lib/generated-client';
let currentContext;
let metadataEditorInfo;
@ -541,7 +541,7 @@ function setFieldVisibilities(context, item) {
hideElement('#fldPath', context);
}
if (item.Type === 'Series' || item.Type === 'Season' || item.Type === 'Episode' || item.Type === 'Movie' || item.Type === 'Trailer' || item.Type === 'Person') {
if ([BaseItemKind.Series, BaseItemKind.Season, BaseItemKind.Episode, BaseItemKind.Movie, BaseItemKind.Trailer, BaseItemKind.Person].includes(item.Type)) {
showElement('#fldOriginalName', context);
} else {
hideElement('#fldOriginalName', context);