Docs: Improve parameter types for various URL functions and filters that also accept `null`.
See #51800. Built from https://develop.svn.wordpress.org/trunk@50340 git-svn-id: http://core.svn.wordpress.org/trunk@49951 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
96edb89edb
commit
4491708fd1
|
@ -3255,7 +3255,7 @@ function home_url( $path = '', $scheme = null ) {
|
|||
*
|
||||
* @global string $pagenow
|
||||
*
|
||||
* @param int $blog_id Optional. Site ID. Default null (current site).
|
||||
* @param int|null $blog_id Optional. Site ID. Default null (current site).
|
||||
* @param string $path Optional. Path relative to the home URL. Default empty.
|
||||
* @param string|null $scheme Optional. Scheme to give the home URL context. Accepts
|
||||
* 'http', 'https', 'relative', 'rest', or null. Default null.
|
||||
|
@ -3313,7 +3313,7 @@ function get_home_url( $blog_id = null, $path = '', $scheme = null ) {
|
|||
* @since 3.0.0
|
||||
*
|
||||
* @param string $path Optional. Path relative to the site URL. Default empty.
|
||||
* @param string $scheme Optional. Scheme to give the site URL context. See set_url_scheme().
|
||||
* @param string|null $scheme Optional. Scheme to give the site URL context. See set_url_scheme().
|
||||
* @return string Site URL link with optional path appended.
|
||||
*/
|
||||
function site_url( $path = '', $scheme = null ) {
|
||||
|
@ -3330,9 +3330,9 @@ function site_url( $path = '', $scheme = null ) {
|
|||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param int $blog_id Optional. Site ID. Default null (current site).
|
||||
* @param int|null $blog_id Optional. Site ID. Default null (current site).
|
||||
* @param string $path Optional. Path relative to the site URL. Default empty.
|
||||
* @param string $scheme Optional. Scheme to give the site URL context. Accepts
|
||||
* @param string|null $scheme Optional. Scheme to give the site URL context. Accepts
|
||||
* 'http', 'https', 'login', 'login_post', 'admin', or
|
||||
* 'relative'. Default null.
|
||||
* @return string Site URL link with optional path appended.
|
||||
|
@ -3371,7 +3371,7 @@ function get_site_url( $blog_id = null, $path = '', $scheme = null ) {
|
|||
*
|
||||
* @since 2.6.0
|
||||
*
|
||||
* @param string $path Optional path relative to the admin URL.
|
||||
* @param string $path Optional. Path relative to the admin URL. Default 'admin'.
|
||||
* @param string $scheme The scheme to use. Default is 'admin', which obeys force_ssl_admin() and is_ssl().
|
||||
* 'http' or 'https' can be passed to force those schemes.
|
||||
* @return string Admin URL link with optional path appended.
|
||||
|
@ -3385,7 +3385,7 @@ function admin_url( $path = '', $scheme = 'admin' ) {
|
|||
*
|
||||
* @since 3.0.0
|
||||
*
|
||||
* @param int $blog_id Optional. Site ID. Default null (current site).
|
||||
* @param int|null $blog_id Optional. Site ID. Default null (current site).
|
||||
* @param string $path Optional. Path relative to the admin URL. Default empty.
|
||||
* @param string $scheme Optional. The scheme to use. Accepts 'http' or 'https',
|
||||
* to force those schemes. Default 'admin', which obeys
|
||||
|
@ -3417,7 +3417,7 @@ function get_admin_url( $blog_id = null, $path = '', $scheme = 'admin' ) {
|
|||
* @since 2.6.0
|
||||
*
|
||||
* @param string $path Optional. Path relative to the includes URL. Default empty.
|
||||
* @param string $scheme Optional. Scheme to give the includes URL context. Accepts
|
||||
* @param string|null $scheme Optional. Scheme to give the includes URL context. Accepts
|
||||
* 'http', 'https', or 'relative'. Default null.
|
||||
* @return string Includes URL link with optional path appended.
|
||||
*/
|
||||
|
@ -3532,7 +3532,7 @@ function plugins_url( $path = '', $plugin = '' ) {
|
|||
* @see set_url_scheme()
|
||||
*
|
||||
* @param string $path Optional. Path relative to the site URL. Default empty.
|
||||
* @param string $scheme Optional. Scheme to give the site URL context. Accepts
|
||||
* @param string|null $scheme Optional. Scheme to give the site URL context. Accepts
|
||||
* 'http', 'https', or 'relative'. Default null.
|
||||
* @return string Site URL link with optional path appended.
|
||||
*/
|
||||
|
@ -3577,7 +3577,7 @@ function network_site_url( $path = '', $scheme = null ) {
|
|||
* @since 3.0.0
|
||||
*
|
||||
* @param string $path Optional. Path relative to the home URL. Default empty.
|
||||
* @param string $scheme Optional. Scheme to give the home URL context. Accepts
|
||||
* @param string|null $scheme Optional. Scheme to give the home URL context. Accepts
|
||||
* 'http', 'https', or 'relative'. Default null.
|
||||
* @return string Home URL link with optional path appended.
|
||||
*/
|
||||
|
|
|
@ -385,7 +385,7 @@ function rest_get_url_prefix() {
|
|||
* @todo Check if this is even necessary
|
||||
* @global WP_Rewrite $wp_rewrite WordPress rewrite component.
|
||||
*
|
||||
* @param int $blog_id Optional. Blog ID. Default of null returns URL for current blog.
|
||||
* @param int|null $blog_id Optional. Blog ID. Default of null returns URL for current blog.
|
||||
* @param string $path Optional. REST route. Default '/'.
|
||||
* @param string $scheme Optional. Sanitization scheme. Default 'rest'.
|
||||
* @return string Full URL to the endpoint.
|
||||
|
@ -443,7 +443,7 @@ function get_rest_url( $blog_id = null, $path = '/', $scheme = 'rest' ) {
|
|||
*
|
||||
* @param string $url REST URL.
|
||||
* @param string $path REST route.
|
||||
* @param int $blog_id Blog ID.
|
||||
* @param int|null $blog_id Blog ID.
|
||||
* @param string $scheme Sanitization scheme.
|
||||
*/
|
||||
return apply_filters( 'rest_url', $url, $path, $blog_id, $scheme );
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.7-beta2-50339';
|
||||
$wp_version = '5.7-beta2-50340';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue