-
Notifications
You must be signed in to change notification settings - Fork 15
Closed
Labels
type: bugIssue that causes incorrect or unexpected behaviorIssue that causes incorrect or unexpected behavior
Description
Description
When the "Return Format" setting of the "post_object" ACF Field Type is set to "Post Object", the GraphQL Resolver doesn't resolve as expected.
Steps to reproduce
- Create an ACF Field Group that is set to "show_in_graphql"
- Add a field of the "repeater" field type, with a nested field of the "post_object" type
- Set the "Return Format" of the "post_object" field type to "Post Object"
- Edit a post that has the field group, and set a Post as the value of the post object field within the repeater
- Query for the repeater field and nested post object field in GraphQL
Expected
I expect to see a Connection that includes the Post(s) set as the value(s) of the post object field:
Actual
A PHP error prevents the GraphQL response:
PHP or JSON export of the ACF Field Group(s)
No response
Additional context
This appears to be related to /src/FieldType/PostObject.php:70
The same logic is found in the PageLink and Relationship fields.
WPGraphQL Version
1.18.0
WPGraphQL For ACF Version
v2.0.0-beta5.1.0
ACF (Advanced Custom Fields) Version. Free or Pro?
latest, PRO
WordPress Version
6.3
PHP Version
8.1
Additional enviornment details
No response
Please confirm that you have searched existing issues in the repo.
- Yes
Please confirm that you have disabled ALL plugins except for WPGraphQL, WPGraphQL For ACF, ACF, etc.
- Yes
- My issue is with compatibility with a specific WordPress plugin, and I have listed all my installed plugins (and version info) above.
Metadata
Metadata
Assignees
Labels
type: bugIssue that causes incorrect or unexpected behaviorIssue that causes incorrect or unexpected behavior

