Compare against default category in the settings instead of hardcoded slug#41956
Merged
Mamaduka merged 3 commits intoWordPress:trunkfrom Jun 28, 2022
Merged
Compare against default category in the settings instead of hardcoded slug#41956Mamaduka merged 3 commits intoWordPress:trunkfrom
Mamaduka merged 3 commits intoWordPress:trunkfrom
Conversation
amustaque97
reviewed
Jun 26, 2022
Member
amustaque97
left a comment
There was a problem hiding this comment.
Tested this locally and it works for me. Thank you for your contribution 👏🏻
I had a glimpse at the static check, not sure why it failed. Though it looks unrelated to your changes.
Mamaduka
reviewed
Jun 28, 2022
packages/editor/src/components/post-publish-panel/maybe-category-panel.js
Outdated
Show resolved
Hide resolved
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What?
Get default category based of setting instead of hardcoded slug.
Why?
Fixes #41955
How?
Instead of using the hardcoded slug, the ID for the default category is fetched from the settings.
Testing Instructions
Test 1
Test 2
wp-admin/options-writing.php