Changeset 52300
- Timestamp:
- 12/01/2021 01:20:36 PM (3 years ago)
- Location:
- trunk/src/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-hook.php
r51530 r52300 169 169 * @since 4.7.0 170 170 * 171 * @param string $hook_name The filter hook to which the function to be removed is hooked. 172 * @param callable $callback The callback to be removed from running when the filter is applied. 173 * @param int $priority The exact priority used when adding the original filter callback. 171 * @param string $hook_name The filter hook to which the function to be removed is hooked. 172 * @param callable|string|array $callback The callback to be removed from running when the filter is applied. 173 * This method can be called unconditionally to speculatively remove 174 * a callback that may or may not exist. 175 * @param int $priority The exact priority used when adding the original filter callback. 174 176 * @return bool Whether the callback existed before it was removed. 175 177 */ … … 202 204 * @since 4.7.0 203 205 * 204 * @param string $hook_name Optional. The name of the filter hook. Default empty. 205 * @param callable|false $callback Optional. The callback to check for. Default false. 206 * @param string $hook_name Optional. The name of the filter hook. Default empty. 207 * @param callable|string|array|false $callback Optional. The callback to check for. 208 * This method can be called unconditionally to speculatively check 209 * a callback that may or may not exist. Default false. 206 210 * @return bool|int If `$callback` is omitted, returns boolean for whether the hook has 207 211 * anything registered. When checking a specific function, the priority -
trunk/src/wp-includes/plugin.php
r50811 r52300 248 248 * @global WP_Hook[] $wp_filter Stores all of the filters and actions. 249 249 * 250 * @param string $hook_name The name of the filter hook. 251 * @param callable|false $callback Optional. The callback to check for. Default false. 250 * @param string $hook_name The name of the filter hook. 251 * @param callable|string|array|false $callback Optional. The callback to check for. 252 * This function can be called unconditionally to speculatively check 253 * a callback that may or may not exist. Default false. 252 254 * @return bool|int If `$callback` is omitted, returns boolean for whether the hook has 253 255 * anything registered. When checking a specific function, the priority … … 278 280 * @global WP_Hook[] $wp_filter Stores all of the filters and actions. 279 281 * 280 * @param string $hook_name The filter hook to which the function to be removed is hooked. 281 * @param callable $callback The name of the function which should be removed. 282 * @param int $priority Optional. The exact priority used when adding the original 283 * filter callback. Default 10. 282 * @param string $hook_name The filter hook to which the function to be removed is hooked. 283 * @param callable|string|array $callback The callback to be removed from running when the filter is applied. 284 * This function can be called unconditionally to speculatively remove 285 * a callback that may or may not exist. 286 * @param int $priority Optional. The exact priority used when adding the original 287 * filter callback. Default 10. 284 288 * @return bool Whether the function existed before it was removed. 285 289 */ … … 531 535 * @see has_filter() has_action() is an alias of has_filter(). 532 536 * 533 * @param string $hook_name The name of the action hook. 534 * @param callable|false $callback Optional. The callback to check for. Default false. 537 * @param string $hook_name The name of the action hook. 538 * @param callable|string|array|false $callback Optional. The callback to check for. 539 * This function can be called unconditionally to speculatively check 540 * a callback that may or may not exist. Default false. 535 541 * @return bool|int If `$callback` is omitted, returns boolean for whether the hook has 536 542 * anything registered. When checking a specific function, the priority … … 553 559 * @since 1.2.0 554 560 * 555 * @param string $hook_name The action hook to which the function to be removed is hooked. 556 * @param callable $callback The name of the function which should be removed. 557 * @param int $priority Optional. The exact priority used when adding the original 558 * action callback. Default 10. 561 * @param string $hook_name The action hook to which the function to be removed is hooked. 562 * @param callable|string|array $callback The name of the function which should be removed. 563 * This function can be called unconditionally to speculatively remove 564 * a callback that may or may not exist. 565 * @param int $priority Optional. The exact priority used when adding the original 566 * action callback. Default 10. 559 567 * @return bool Whether the function is removed. 560 568 */ … … 925 933 * `$hook_name` and `$priority` are no longer used, 926 934 * and the function always returns a string. 935 * 927 936 * @access private 928 937 * 929 * @param string $hook_name Unused. The name of the filter to build ID for. 930 * @param callable $callback The function to generate ID for. 931 * @param int $priority Unused. The order in which the functions 932 * associated with a particular action are executed. 938 * @param string $hook_name Unused. The name of the filter to build ID for. 939 * @param callable|string|array $callback The callback to generate ID for. The callback may 940 * or may not exist. 941 * @param int $priority Unused. The order in which the functions 942 * associated with a particular action are executed. 933 943 * @return string Unique function ID for usage as array key. 934 944 */
Note: See TracChangeset
for help on using the changeset viewer.