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

Fix legacy use of get_terms() #111

Open
GaryJones opened this issue Aug 16, 2024 · 0 comments
Open

Fix legacy use of get_terms() #111

GaryJones opened this issue Aug 16, 2024 · 0 comments
Assignees
Milestone

Comments

@GaryJones
Copy link
Contributor

Prior to WP 4.5 (no longer supported by this plugin), get_terms() function had a signature of get_terms( $taxonomy, $args ). Since then, it is now get_terms( $args ). The second parameter is deprecated, and the taxonomy is found under the $args['taxonomy]` field.

$zones = get_terms( $this->zone_taxonomy, $args );
uses the legacy format of the function call, and generates a warning in WordPressCS. This should be updated to use the modern signature. Tests should ideally be written to ensure that the zone_taxonomy class property is merged into the $args for the get_zones() function in which the get_terms() call is found.

@GaryJones GaryJones added this to the Next milestone Aug 16, 2024
@GaryJones GaryJones self-assigned this Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant