diff options
| author | Armand Philippot <git@armandphilippot.com> | 2021-12-16 18:22:08 +0100 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2021-12-16 18:22:08 +0100 |
| commit | 0ef4f77954ba54b52b96c70a8bffe96804bd222d (patch) | |
| tree | 7fe68b05271625f72f750786e1a94b71942d2cd5 /src/services/graphql/post.ts | |
| parent | a4f865224e0e395c7e29bb3b7279a5101b554d2c (diff) | |
chore: display featuredImage and meta on posts list
Diffstat (limited to 'src/services/graphql/post.ts')
| -rw-r--r-- | src/services/graphql/post.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/services/graphql/post.ts b/src/services/graphql/post.ts index c7144fc..2ce918b 100644 --- a/src/services/graphql/post.ts +++ b/src/services/graphql/post.ts @@ -108,7 +108,7 @@ export const getPostBySlug: GetPostByReturn = async (slug: string) => { const content = rawPost.postBy.contentParts.afterMore; const featuredImage = rawPost.postBy.featuredImage ? rawPost.postBy.featuredImage.node - : {}; + : null; const date = { publication: rawPost.postBy.date, update: rawPost.postBy.modified, @@ -117,8 +117,8 @@ export const getPostBySlug: GetPostByReturn = async (slug: string) => { const subjects = rawPost.postBy.acfPosts.postsInSubject ? rawPost.postBy.acfPosts.postsInSubject : []; - const thematics = rawPost.postBy.acfPosts.postsInThematics - ? rawPost.postBy.acfPosts.postsInThematics + const thematics = rawPost.postBy.acfPosts.postsInThematic + ? rawPost.postBy.acfPosts.postsInThematic : []; const formattedPost: Article = { |
