mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-06 20:10:12 +02:00
change "Fields" query parameter to array (#1733)
* change "Fields" query parameter to array * platformToTarget.key() -> to array
This commit is contained in:
committed by
GitHub
parent
9dad934a40
commit
2c546867a8
@@ -15,9 +15,9 @@ const __dirname = path.dirname(__filename);
|
||||
// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
|
||||
export default async function afterAllArtifactBuild(buildResult) {
|
||||
// Check if this build includes Linux as a target
|
||||
const isLinux = buildResult.platformToTargets
|
||||
.keys()
|
||||
.some((platform) => platform.name === 'linux');
|
||||
const isLinux = Array.from(buildResult.platformToTargets.keys()).some(
|
||||
(platform) => platform.name === 'linux',
|
||||
);
|
||||
|
||||
if (isLinux) {
|
||||
const updateScriptPath = path.join(__dirname, 'update-app-stream.mjs');
|
||||
|
||||
@@ -54,15 +54,38 @@ const VERSION_INFO: VersionInfo = [
|
||||
];
|
||||
|
||||
const JF_FIELDS = {
|
||||
ALBUM_ARTIST_DETAIL: 'Genres, Overview, SortName, ProviderIds',
|
||||
ALBUM_ARTIST_LIST: 'Genres, DateCreated, ExternalUrls, Overview, SortName, ProviderIds',
|
||||
ALBUM_DETAIL: 'Genres, DateCreated, ChildCount, People, Tags, ProviderIds',
|
||||
ALBUM_LIST: 'People, Tags, Studios, SortName, UserData, ProviderIds, ChildCount',
|
||||
FOLDER: 'Genres, DateCreated, MediaSources, UserData, ParentId',
|
||||
GENRE: 'ItemCounts',
|
||||
PLAYLIST_DETAIL: 'Genres, DateCreated, MediaSources, ChildCount, ParentId, SortName',
|
||||
PLAYLIST_LIST: 'ChildCount, Genres, DateCreated, ParentId, Overview',
|
||||
SONG: 'Genres, DateCreated, MediaSources, ParentId, People, Tags, SortName, UserData, ProviderIds',
|
||||
ALBUM_ARTIST_DETAIL: ['Genres', 'Overview', 'SortName', 'ProviderIds'],
|
||||
ALBUM_ARTIST_LIST: [
|
||||
'Genres',
|
||||
'DateCreated',
|
||||
'ExternalUrls',
|
||||
'Overview',
|
||||
'SortName',
|
||||
'ProviderIds',
|
||||
],
|
||||
ALBUM_DETAIL: ['Genres', 'DateCreated', 'ChildCount', 'People', 'Tags', 'ProviderIds'],
|
||||
ALBUM_LIST: ['People', 'Tags', 'Studios', 'SortName', 'ProviderIds', 'ChildCount'],
|
||||
FOLDER: ['Genres', 'DateCreated', 'MediaSources', 'ParentId'],
|
||||
GENRE: ['ItemCounts'],
|
||||
PLAYLIST_DETAIL: [
|
||||
'Genres',
|
||||
'DateCreated',
|
||||
'MediaSources',
|
||||
'ChildCount',
|
||||
'ParentId',
|
||||
'SortName',
|
||||
],
|
||||
PLAYLIST_LIST: ['ChildCount', 'Genres', 'DateCreated', 'ParentId', 'Overview'],
|
||||
SONG: [
|
||||
'Genres',
|
||||
'DateCreated',
|
||||
'MediaSources',
|
||||
'ParentId',
|
||||
'People',
|
||||
'Tags',
|
||||
'SortName',
|
||||
'ProviderIds',
|
||||
],
|
||||
} as const;
|
||||
|
||||
export const JellyfinController: InternalControllerEndpoint = {
|
||||
|
||||
@@ -107,7 +107,7 @@ const baseParameters = z.object({
|
||||
ExcludeArtistIds: z.string().optional(),
|
||||
ExcludeItemIds: z.string().optional(),
|
||||
ExcludeItemTypes: z.string().optional(),
|
||||
Fields: z.string().optional(),
|
||||
Fields: z.array(z.string()).readonly().optional(),
|
||||
FolderId: z.string().optional(),
|
||||
ImageTypeLimit: z.number().optional(),
|
||||
IncludeArtists: z.boolean().optional(),
|
||||
@@ -757,7 +757,7 @@ const serverInfo = z.object({
|
||||
});
|
||||
|
||||
const similarSongsParameters = z.object({
|
||||
Fields: z.string().optional(),
|
||||
Fields: z.array(z.string()).readonly().optional(),
|
||||
Limit: z.number().optional(),
|
||||
UserId: z.string().optional(),
|
||||
});
|
||||
@@ -806,7 +806,7 @@ const folderList = pagination.extend({
|
||||
});
|
||||
|
||||
const folderParameters = z.object({
|
||||
Fields: z.string().optional(),
|
||||
Fields: z.array(z.string()).readonly().optional(),
|
||||
ParentId: z.string().optional(),
|
||||
SortBy: z.string().optional(),
|
||||
SortOrder: z.enum(sortOrderValues).optional(),
|
||||
|
||||
Reference in New Issue
Block a user