mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
- in the end, the error was due to not asking for the id of the author back of the Post.. grrr.... why couldn't we get better error messages!! - Co-authored-by: Moriz Wahl <moriz.wahl@gmx.de>
28 lines
433 B
JavaScript
28 lines
433 B
JavaScript
import gql from 'graphql-tag'
|
|
|
|
export const findResourcesQuery = gql`
|
|
query($query: String!) {
|
|
findResources(query: $query, limit: 5) {
|
|
__typename
|
|
... on Post {
|
|
id
|
|
title
|
|
slug
|
|
commentsCount
|
|
shoutedCount
|
|
createdAt
|
|
author {
|
|
id
|
|
name
|
|
}
|
|
}
|
|
... on User {
|
|
id
|
|
name
|
|
slug
|
|
avatar
|
|
}
|
|
}
|
|
}
|
|
`
|