Skip to content

On ContentType union in nodeByUri returns incorrect isPostsPage #2514

@blakewilson

Description

@blakewilson

Description

...on ContentType union in nodeByUri returns incorrect isPostsPage

Steps to reproduce

  1. Set your WordPress instance to have a static posts page
  2. Use the following query to query it by uri (in my case /blog):
    query GetNodeByUri($uri: String!) {
      nodeByUri(uri: $uri) {
        ... on ContentType {
          isPostsPage
        }
      }
    }
  3. Notice isPostsPage returns false

Screenshots

Screen Shot 2022-09-09 at 2 50 30 PM

Screen Shot 2022-09-09 at 2 50 42 PM

Additional context

No response

WPGraphQL Version

1.10.0

WordPress Version

6.0.2

PHP Version

7.4.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.

  • 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

No one assigned

    Labels

    status: in reviewAwaiting review before merging or closingtype: bugIssue that causes incorrect or unexpected behavior

    Type

    No type

    Projects

    Status

    ✅ Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions