return items

This commit is contained in:
SrGooglo 2025-02-11 16:15:35 +00:00
parent bca40318bd
commit f70c9ff53e
2 changed files with 37 additions and 36 deletions

View File

@ -28,6 +28,7 @@ export default {
release.listLength = totalTracks release.listLength = totalTracks
release.items = tracks release.items = tracks
release.list = tracks
return release return release
}, },

View File

@ -28,8 +28,8 @@ export default {
if (req.query.resolveItemsData === "true") { if (req.query.resolveItemsData === "true") {
releases = await Promise.all( releases = await Promise.all(
playlists.map(async playlist => { playlists.map(async (playlist) => {
playlist.list = await Track.find({ playlist.items = await Track.find({
_id: [...playlist.list], _id: [...playlist.list],
}) })
@ -42,5 +42,5 @@ export default {
total_length: await MusicRelease.countDocuments(searchQuery), total_length: await MusicRelease.countDocuments(searchQuery),
items: releases, items: releases,
} }
} },
} }