Added tags to chapters in API.
This commit is contained in:
parent
e55bc1ef33
commit
a45c5f8f37
|
@ -52,6 +52,13 @@ const releaseFields = `
|
||||||
duration
|
duration
|
||||||
title
|
title
|
||||||
description
|
description
|
||||||
|
tags: chaptersTags {
|
||||||
|
tag {
|
||||||
|
id
|
||||||
|
name
|
||||||
|
slug
|
||||||
|
}
|
||||||
|
}
|
||||||
poster: chaptersPosterByChapterId {
|
poster: chaptersPosterByChapterId {
|
||||||
media {
|
media {
|
||||||
id
|
id
|
||||||
|
@ -204,6 +211,7 @@ function curateGraphqlRelease(release) {
|
||||||
tags: release.tags.map(tag => tag.tag),
|
tags: release.tags.map(tag => tag.tag),
|
||||||
...(release.chapters && { chapters: release.chapters.map(chapter => ({
|
...(release.chapters && { chapters: release.chapters.map(chapter => ({
|
||||||
...chapter,
|
...chapter,
|
||||||
|
tags: chapter.tags.map(tag => tag.tag),
|
||||||
poster: chapter.poster?.media || null,
|
poster: chapter.poster?.media || null,
|
||||||
photos: chapter.photos.map(photo => photo.media),
|
photos: chapter.photos.map(photo => photo.media),
|
||||||
})) }),
|
})) }),
|
||||||
|
|
Loading…
Reference in New Issue