Docs: Document default values for optional parameters in wp_insert_attachment().

This adds the missing mentions of default value for the `$file` and `$parent_post_id` parameters.

Follow-up to [2921], [3092], [3303], [3851], [6155], [6379], [8669], [15590], [28788], [38408], [49936], [55021].

Props wpfy.
Fixes #58043.
Built from https://develop.svn.wordpress.org/trunk@55617


git-svn-id: http://core.svn.wordpress.org/trunk@55129 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2023-04-02 13:01:23 +00:00
parent df4ed4015a
commit a415951b8f
2 changed files with 3 additions and 3 deletions

View File

@ -6135,8 +6135,8 @@ function is_local_attachment( $url ) {
* @see wp_insert_post() * @see wp_insert_post()
* *
* @param string|array $args Arguments for inserting an attachment. * @param string|array $args Arguments for inserting an attachment.
* @param string|false $file Optional. Filename. * @param string|false $file Optional. Filename. Default false.
* @param int $parent_post_id Optional. Parent post ID. * @param int $parent_post_id Optional. Parent post ID. Default 0.
* @param bool $wp_error Optional. Whether to return a WP_Error on failure. Default false. * @param bool $wp_error Optional. Whether to return a WP_Error on failure. Default false.
* @param bool $fire_after_hooks Optional. Whether to fire the after insert hooks. Default true. * @param bool $fire_after_hooks Optional. Whether to fire the after insert hooks. Default true.
* @return int|WP_Error The attachment ID on success. The value 0 or WP_Error on failure. * @return int|WP_Error The attachment ID on success. The value 0 or WP_Error on failure.

View File

@ -16,7 +16,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '6.3-alpha-55616'; $wp_version = '6.3-alpha-55617';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.