Docs: Correct and improve inline docs for parameters that accept a callback function.

See #49572

git-svn-id: https://develop.svn.wordpress.org/trunk@48473 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
John Blackbourn
2020-07-14 11:54:26 +00:00
parent 585f623b4d
commit fa9e258750
10 changed files with 60 additions and 60 deletions

View File

@@ -4149,7 +4149,7 @@ function wp_send_json_error( $data = null, $status_code = null ) {
}
/**
* Checks that a JSONP callback is a valid JavaScript callback.
* Checks that a JSONP callback is a valid JavaScript callback name.
*
* Only allows alphanumeric characters and the dot character in callback
* function names. This helps to mitigate XSS attacks caused by directly
@@ -4157,8 +4157,8 @@ function wp_send_json_error( $data = null, $status_code = null ) {
*
* @since 4.6.0
*
* @param string $callback Supplied JSONP callback function.
* @return bool True if valid callback, otherwise false.
* @param string $callback Supplied JSONP callback function name.
* @return bool Whether the callback function name is valid.
*/
function wp_check_jsonp_callback( $callback ) {
if ( ! is_string( $callback ) ) {