Skip to content

Conversation

@jasonbahl
Copy link
Collaborator

@jasonbahl jasonbahl commented Jan 15, 2025

What does this implement/fix? Explain your changes.

This fixes a bug where the createPost mutation would assign the "default category" to newly created posts even when other categories were explicitly assigned during the mutation.

The default category should only be assigned if other categories are not assigned during the creation.

Does this close any currently open issues?

closes #3269

Any other comments?

Before

Submitting the createPost mutation with categories would create the post with the submitted categories, but also include the default category.

CleanShot 2025-01-15 at 16 32 04

After

Submitting the createPost mutation with categories would create the post with the submitted categories, and not include the default category.

CleanShot 2025-01-15 at 16 32 30

@jasonbahl jasonbahl changed the title release: v1.30.0 fix: default cat should not be added when other categories are added Jan 15, 2025
@coveralls
Copy link

coveralls commented Jan 15, 2025

Coverage Status

coverage: 84.352% (+0.004%) from 84.348%
when pulling a8cb27e on jasonbahl:fix/3269-default-cat-should-not-be-added-when-other-categories-are-added
into 1e6e008 on wp-graphql:develop.

@qlty-cloud-legacy
Copy link

Code Climate has analyzed commit a8cb27e and detected 0 issues on this pull request.

View more on Code Climate.

@jasonbahl jasonbahl merged commit 0c4ee0c into wp-graphql:develop Jan 16, 2025
36 checks passed
@jasonbahl jasonbahl mentioned this pull request Jan 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Uncategorized is added by default when adding a post

3 participants