Improve various `@param` docs.
See #30224. Built from https://develop.svn.wordpress.org/trunk@30673 git-svn-id: http://core.svn.wordpress.org/trunk@30663 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
d097e7cf83
commit
ba914c7df1
|
@ -343,10 +343,10 @@ function update_option( $option, $value ) {
|
||||||
*
|
*
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*
|
*
|
||||||
* @param string $option Name of option to add. Expected to not be SQL-escaped.
|
* @param string $option Name of option to add. Expected to not be SQL-escaped.
|
||||||
* @param mixed $value Optional. Option value. Must be serializable if non-scalar. Expected to not be SQL-escaped.
|
* @param mixed $value Optional. Option value. Must be serializable if non-scalar. Expected to not be SQL-escaped.
|
||||||
* @param mixed $deprecated Optional. Description. Not used anymore.
|
* @param string $deprecated Optional. Description. Not used anymore.
|
||||||
* @param bool $autoload Optional. Default is enabled. Whether to load the option when WordPress starts up.
|
* @param string|bool $autoload Optional. Default is enabled. Whether to load the option when WordPress starts up.
|
||||||
* @return bool False if option was not added and true if option was added.
|
* @return bool False if option was not added and true if option was added.
|
||||||
*/
|
*/
|
||||||
function add_option( $option, $value = '', $deprecated = '', $autoload = 'yes' ) {
|
function add_option( $option, $value = '', $deprecated = '', $autoload = 'yes' ) {
|
||||||
|
@ -775,7 +775,7 @@ function get_user_setting( $name, $default = false ) {
|
||||||
*
|
*
|
||||||
* @param string $name The name of the setting.
|
* @param string $name The name of the setting.
|
||||||
* @param string $value The value for the setting.
|
* @param string $value The value for the setting.
|
||||||
* @return bool true if set successfully/false if not.
|
* @return null|bool true if set successfully/false if not.
|
||||||
*/
|
*/
|
||||||
function set_user_setting( $name, $value ) {
|
function set_user_setting( $name, $value ) {
|
||||||
|
|
||||||
|
@ -797,8 +797,8 @@ function set_user_setting( $name, $value ) {
|
||||||
*
|
*
|
||||||
* @since 2.7.0
|
* @since 2.7.0
|
||||||
*
|
*
|
||||||
* @param mixed $names The name or array of names of the setting to be deleted.
|
* @param string $names The name or array of names of the setting to be deleted.
|
||||||
* @return bool true if deleted successfully/false if not.
|
* @return null|bool true if deleted successfully/false if not.
|
||||||
*/
|
*/
|
||||||
function delete_user_setting( $names ) {
|
function delete_user_setting( $names ) {
|
||||||
|
|
||||||
|
@ -868,7 +868,7 @@ function get_all_user_settings() {
|
||||||
* @since 2.8.0
|
* @since 2.8.0
|
||||||
*
|
*
|
||||||
* @param array $user_settings
|
* @param array $user_settings
|
||||||
* @return bool
|
* @return null|bool
|
||||||
*/
|
*/
|
||||||
function wp_set_all_user_settings( $user_settings ) {
|
function wp_set_all_user_settings( $user_settings ) {
|
||||||
global $_updated_user_settings;
|
global $_updated_user_settings;
|
||||||
|
|
|
@ -176,7 +176,7 @@ function is_post_type_archive( $post_types = '' ) {
|
||||||
* @since 2.0.0
|
* @since 2.0.0
|
||||||
* @uses $wp_query
|
* @uses $wp_query
|
||||||
*
|
*
|
||||||
* @param mixed $attachment Attachment ID, title, slug, or array of such.
|
* @param int|string|array $attachment Attachment ID, title, slug, or array of such.
|
||||||
* @return bool
|
* @return bool
|
||||||
*/
|
*/
|
||||||
function is_attachment( $attachment = '' ) {
|
function is_attachment( $attachment = '' ) {
|
||||||
|
@ -276,8 +276,8 @@ function is_tag( $tag = '' ) {
|
||||||
* @since 2.5.0
|
* @since 2.5.0
|
||||||
* @uses $wp_query
|
* @uses $wp_query
|
||||||
*
|
*
|
||||||
* @param mixed $taxonomy Optional. Taxonomy slug or slugs.
|
* @param string|array $taxonomy Optional. Taxonomy slug or slugs.
|
||||||
* @param mixed $term Optional. Term ID, name, slug or array of Term IDs, names, and slugs.
|
* @param int|string|array $term Optional. Term ID, name, slug or array of Term IDs, names, and slugs.
|
||||||
* @return bool
|
* @return bool
|
||||||
*/
|
*/
|
||||||
function is_tax( $taxonomy = '', $term = '' ) {
|
function is_tax( $taxonomy = '', $term = '' ) {
|
||||||
|
@ -2100,7 +2100,7 @@ class WP_Query {
|
||||||
*
|
*
|
||||||
* @since 3.7.0
|
* @since 3.7.0
|
||||||
*
|
*
|
||||||
* @param array Terms to check.
|
* @param array $terms Terms to check.
|
||||||
* @return array Terms that are not stopwords.
|
* @return array Terms that are not stopwords.
|
||||||
*/
|
*/
|
||||||
protected function parse_search_terms( $terms ) {
|
protected function parse_search_terms( $terms ) {
|
||||||
|
@ -4540,7 +4540,7 @@ class WP_Query {
|
||||||
*
|
*
|
||||||
* @since 4.1.0
|
* @since 4.1.0
|
||||||
*
|
*
|
||||||
* @param object $post Post data.
|
* @param WP_Post $post Post data.
|
||||||
* @return bool True when finished.
|
* @return bool True when finished.
|
||||||
*/
|
*/
|
||||||
public function setup_postdata( $post ) {
|
public function setup_postdata( $post ) {
|
||||||
|
@ -4608,8 +4608,6 @@ class WP_Query {
|
||||||
* restores the $post global to the current post in this query.
|
* restores the $post global to the current post in this query.
|
||||||
*
|
*
|
||||||
* @since 3.7.0
|
* @since 3.7.0
|
||||||
*
|
|
||||||
* @return bool
|
|
||||||
*/
|
*/
|
||||||
public function reset_postdata() {
|
public function reset_postdata() {
|
||||||
if ( ! empty( $this->post ) ) {
|
if ( ! empty( $this->post ) ) {
|
||||||
|
|
|
@ -438,7 +438,7 @@ function wp_get_post_revisions( $post_id = 0, $args = null ) {
|
||||||
*
|
*
|
||||||
* @since 3.6.0
|
* @since 3.6.0
|
||||||
*
|
*
|
||||||
* @param object $post The post object.
|
* @param WP_Post $post The post object.
|
||||||
* @return bool True if number of revisions to keep isn't zero, false otherwise.
|
* @return bool True if number of revisions to keep isn't zero, false otherwise.
|
||||||
*/
|
*/
|
||||||
function wp_revisions_enabled( $post ) {
|
function wp_revisions_enabled( $post ) {
|
||||||
|
@ -572,7 +572,7 @@ function _wp_get_post_revision_version( $revision ) {
|
||||||
* @since 3.6.0
|
* @since 3.6.0
|
||||||
* @access private
|
* @access private
|
||||||
*
|
*
|
||||||
* @param object $post Post object
|
* @param WP_Post $post Post object
|
||||||
* @param array $revisions Current revisions of the post
|
* @param array $revisions Current revisions of the post
|
||||||
* @return bool true if the revisions were upgraded, false if problems
|
* @return bool true if the revisions were upgraded, false if problems
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -819,7 +819,7 @@ class WP_Tax_Query {
|
||||||
* @access public
|
* @access public
|
||||||
*
|
*
|
||||||
* @param string $relation Raw relation key from the query argument.
|
* @param string $relation Raw relation key from the query argument.
|
||||||
* @return Sanitized relation ('AND' or 'OR').
|
* @return string Sanitized relation ('AND' or 'OR').
|
||||||
*/
|
*/
|
||||||
public function sanitize_relation( $relation ) {
|
public function sanitize_relation( $relation ) {
|
||||||
if ( 'OR' === strtoupper( $relation ) ) {
|
if ( 'OR' === strtoupper( $relation ) ) {
|
||||||
|
@ -3736,7 +3736,7 @@ function get_object_term_cache($id, $taxonomy) {
|
||||||
*
|
*
|
||||||
* @param string|array $object_ids Single or list of term object ID(s)
|
* @param string|array $object_ids Single or list of term object ID(s)
|
||||||
* @param array|string $object_type The taxonomy object type
|
* @param array|string $object_type The taxonomy object type
|
||||||
* @return null|bool Null value is given with empty $object_ids. False if
|
* @return null|false Null value is given with empty $object_ids. False if
|
||||||
*/
|
*/
|
||||||
function update_object_term_cache($object_ids, $object_type) {
|
function update_object_term_cache($object_ids, $object_type) {
|
||||||
if ( empty($object_ids) )
|
if ( empty($object_ids) )
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.1-beta2-30672';
|
$wp_version = '4.1-beta2-30673';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 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.
|
||||||
|
|
Loading…
Reference in New Issue