18
18
*
19
19
* Note: Do not use before the {@see 'abilities_api_init'} hook.
20
20
*
21
- * @see WP_Abilities_Registry::register()
22
- *
23
21
* @since 0.1.0
24
22
*
23
+ * @see WP_Abilities_Registry::register()
24
+ *
25
25
* @param string $name The name of the ability. The name must be a string containing a namespace
26
26
* prefix, i.e. `my-plugin/my-ability`. It can only contain lowercase
27
27
* alphanumeric characters, dashes and the forward slash.
@@ -63,10 +63,10 @@ function wp_register_ability( string $name, array $properties = array() ): ?WP_A
63
63
/**
64
64
* Unregisters an ability using Abilities API.
65
65
*
66
- * @see WP_Abilities_Registry::unregister()
67
- *
68
66
* @since 0.1.0
69
67
*
68
+ * @see WP_Abilities_Registry::unregister()
69
+ *
70
70
* @param string $name The name of the registered ability, with its namespace.
71
71
* @return ?\WP_Ability The unregistered ability instance on success, null on failure.
72
72
*/
@@ -77,10 +77,10 @@ function wp_unregister_ability( string $name ): ?WP_Ability {
77
77
/**
78
78
* Retrieves a registered ability using Abilities API.
79
79
*
80
- * @see WP_Abilities_Registry::get_registered()
81
- *
82
80
* @since 0.1.0
83
81
*
82
+ * @see WP_Abilities_Registry::get_registered()
83
+ *
84
84
* @param string $name The name of the registered ability, with its namespace.
85
85
* @return ?\WP_Ability The registered ability instance, or null if it is not registered.
86
86
*/
@@ -91,10 +91,10 @@ function wp_get_ability( string $name ): ?WP_Ability {
91
91
/**
92
92
* Retrieves all registered abilities using Abilities API.
93
93
*
94
- * @see WP_Abilities_Registry::get_all_registered()
95
- *
96
94
* @since 0.1.0
97
95
*
96
+ * @see WP_Abilities_Registry::get_all_registered()
97
+ *
98
98
* @return \WP_Ability[] The array of registered abilities.
99
99
*/
100
100
function wp_get_abilities (): array {
0 commit comments