graphql issue #1386
Replies: 2 comments
-
Hmmm, this is certainly strange. I've just created a minimal reproduction config and a corresponding GraphQL query but can't reproduce. Config: export default buildConfig({
collections: [
{
slug: 'users',
auth: true,
fields: [
{
name: 'avatar',
type: 'upload',
relationTo: 'media',
},
],
},
{
slug: 'posts',
fields: [
{
name: 'title',
type: 'text',
required: true,
},
{
name: 'owner',
type: 'relationship',
relationTo: 'users',
},
],
},
{
slug: 'media',
upload: true,
fields: [
{
name: 'alt',
type: 'text',
},
],
},
],
}); Query: query {
Users {
docs {
email
id
avatar {
alt
}
}
}
allMedia {
docs {
alt
}
}
Posts {
docs {
owner {
email
avatar {
alt
}
}
}
}
} Is there something in specific that you may be doing with hooks or access control? Because access control could certainly make some "populations" from relationship fields return I'm going to convert this to a discussion but let's see if we can get to the bottom of this. If we identify a bug, we can open a new issue! |
Beta Was this translation helpful? Give feedback.
-
This bug doesn't exist on our server anymore. @zhounewz |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Bug Report
Current Behavior
Strange bug, the avatar in Author and the author field in Articles originally exist, but each query returns null alternately;
Expected Behavior
Possible Solution
Steps to Reproduce
Detailed Description
Beta Was this translation helpful? Give feedback.
All reactions