Skip to content

Commit 7b719ec

Browse files
committed
Abilities API: Ensure public method is used in the codebase
Discovered when syncing code back to Abilities API repository in WordPress/abilities-api#126. Follow-up to [61032]. See #64098. Built from https://develop.svn.wordpress.org/trunk@61059 git-svn-id: https://core.svn.wordpress.org/trunk@60395 1a063a9b-81f0-0310-95a4-ce76da25c4cd
1 parent 89a9c30 commit 7b719ec

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

wp-includes/abilities-api/class-wp-abilities-registry.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,7 @@ public function register( string $name, array $args ): ?WP_Ability {
121121

122122
// Validate ability category exists if provided (will be validated as required in WP_Ability).
123123
if ( isset( $args['category'] ) ) {
124-
$category_registry = WP_Ability_Categories_Registry::get_instance();
125-
if ( ! $category_registry->is_registered( $args['category'] ) ) {
124+
if ( ! wp_has_ability_category( $args['category'] ) ) {
126125
_doing_it_wrong(
127126
__METHOD__,
128127
sprintf(

wp-includes/version.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
*
1717
* @global string $wp_version
1818
*/
19-
$wp_version = '6.9-beta1-61058';
19+
$wp_version = '6.9-beta1-61059';
2020

2121
/**
2222
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.

0 commit comments

Comments
 (0)