Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/category not in support #2174

Merged
merged 14 commits into from
May 27, 2021
Merged

Conversation

oscarssanchez
Copy link
Contributor

@oscarssanchez oscarssanchez commented Apr 17, 2021

Description of the Change

This PR adds support for category__not_in param and fixes #1947

Alternate Designs

Benefits

Possible Drawbacks

Verification Process

1.- Create a post and add to a test category
2.- Use pre_get_posts or WP_Query to search with category__not_in set to the test category id
3.- Post should be excluded

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests passed.

Applicable Issues

Changelog Entry

@oscarssanchez oscarssanchez changed the title WIP: Feature/category not in support Feature/category not in support Apr 23, 2021
@oscarssanchez
Copy link
Contributor Author

Added tag__not_in support @felipeelia can you please take another peek?

@oscarssanchez oscarssanchez removed their assignment May 4, 2021
@felipeelia
Copy link
Member

felipeelia commented May 6, 2021

@oscarssanchez I'm terribly sorry for not seeing this before but can we wrap those (array) $variable statements with an array_values() call? That way we avoid problems if some plugin or theme decides to send an associative array. Again, sorry for the back and forth here.
When you have it done, can you please assign it to @Rahmon to review? Thanks!

@felipeelia felipeelia requested review from Rahmon and removed request for felipeelia May 6, 2021 14:21
Rahmon
Rahmon previously approved these changes May 18, 2021
Copy link
Contributor

@Rahmon Rahmon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@Rahmon
Copy link
Contributor

Rahmon commented May 19, 2021

@oscarssanchez can you please update the PR to be able to merge?

@Rahmon Rahmon removed their assignment May 19, 2021
@oscarssanchez
Copy link
Contributor Author

Branch updated @Rahmon :)

@felipeelia felipeelia added this to the 3.6.0 milestone May 27, 2021
@felipeelia felipeelia merged commit e950aa9 into develop May 27, 2021
@felipeelia felipeelia deleted the feature/category-not-in-support branch May 27, 2021 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support the full category__not_in parameter in WP_Query
3 participants