join path with library path

This commit is contained in:
Kendall Garner 2025-07-01 21:51:09 -07:00
parent ce6aaa709f
commit 6f5dd4881a
No known key found for this signature in database
GPG key ID: 9355F387FE765C94
2 changed files with 4 additions and 1 deletions

View file

@ -175,7 +175,9 @@ const normalizeSong = (
lastPlayedAt: normalizePlayDate(item),
lyrics: item.lyrics ? item.lyrics : null,
name: item.title,
path: item.path,
// Thankfully, Windows is merciful and allows a mix of separators. So, we can use the
// POSIX separator here instead
path: (item.libraryPath ? item.libraryPath + '/' : '') + item.path,
peak:
item.rgAlbumPeak || item.rgTrackPeak
? { album: item.rgAlbumPeak, track: item.rgTrackPeak }

View file

@ -205,6 +205,7 @@ const song = z.object({
id: z.string(),
imageFiles: z.string().optional(),
largeImageUrl: z.string().optional(),
libraryPath: z.string().optional(),
lyrics: z.string().optional(),
mbzAlbumArtistId: z.string().optional(),
mbzAlbumId: z.string().optional(),