mirror of
https://github.com/jeffvli/feishin.git
synced 2026-07-19 00:46:35 +02:00
add missing album gain to Jellyfin (#2199)
This commit is contained in:
@@ -160,15 +160,19 @@ const normalizeSong = (
|
|||||||
duration: item.RunTimeTicks / TICKS_PER_MS,
|
duration: item.RunTimeTicks / TICKS_PER_MS,
|
||||||
explicitStatus: null,
|
explicitStatus: null,
|
||||||
gain:
|
gain:
|
||||||
item.NormalizationGain !== undefined
|
item.AlbumNormalizationGain !== undefined ||
|
||||||
|
item.NormalizationGain !== undefined ||
|
||||||
|
item.LUFS !== undefined
|
||||||
? {
|
? {
|
||||||
track: item.NormalizationGain,
|
album: item.AlbumNormalizationGain,
|
||||||
|
track:
|
||||||
|
item.NormalizationGain !== undefined
|
||||||
|
? item.NormalizationGain
|
||||||
|
: item.LUFS !== undefined
|
||||||
|
? -18 - item.LUFS
|
||||||
|
: undefined,
|
||||||
}
|
}
|
||||||
: item.LUFS
|
: null,
|
||||||
? {
|
|
||||||
track: -18 - item.LUFS,
|
|
||||||
}
|
|
||||||
: null,
|
|
||||||
genres: item.GenreItems?.map((entry) => ({
|
genres: item.GenreItems?.map((entry) => ({
|
||||||
_itemType: LibraryItem.GENRE,
|
_itemType: LibraryItem.GENRE,
|
||||||
_serverId: server?.id || '',
|
_serverId: server?.id || '',
|
||||||
|
|||||||
@@ -471,6 +471,7 @@ const song = z.object({
|
|||||||
AlbumArtist: z.string(),
|
AlbumArtist: z.string(),
|
||||||
AlbumArtists: z.array(genericItem),
|
AlbumArtists: z.array(genericItem),
|
||||||
AlbumId: z.string().optional(),
|
AlbumId: z.string().optional(),
|
||||||
|
AlbumNormalizationGain: z.number().optional(),
|
||||||
AlbumPrimaryImageTag: z.string(),
|
AlbumPrimaryImageTag: z.string(),
|
||||||
ArtistItems: z.array(genericItem),
|
ArtistItems: z.array(genericItem),
|
||||||
Artists: z.array(z.string()),
|
Artists: z.array(z.string()),
|
||||||
|
|||||||
Reference in New Issue
Block a user