Docs: Improve various globals documentation, as per documentation standards.

Props upadalavipul.
See #57069, #56792.


git-svn-id: https://develop.svn.wordpress.org/trunk@54953 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jb Audras 2022-12-09 11:52:58 +00:00
parent cb99ef08f0
commit ee09cadd94
9 changed files with 21 additions and 0 deletions

View File

@ -30,6 +30,7 @@ class WP_Debug_Data {
*
* @throws ImagickException
* @global wpdb $wpdb WordPress database abstraction object.
* @global $_wp_theme_features
*
* @return array The debug data for the site.
*/
@ -1558,6 +1559,8 @@ class WP_Debug_Data {
*
* @since 5.2.0
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @return int The size of the database, in bytes.
*/
public static function get_database_size() {

View File

@ -1284,6 +1284,8 @@ class WP_Site_Health {
*
* @since 5.2.0
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @return array The test results.
*/
public function get_test_utf8mb4_support() {

View File

@ -524,6 +524,8 @@ class WP_User_Search {
*
* @since 2.1.0
* @access public
*
* @global wpdb $wpdb WordPress database abstraction object.
*/
public function prepare_query() {
global $wpdb;
@ -562,6 +564,8 @@ class WP_User_Search {
*
* @since 2.1.0
* @access public
*
* @global wpdb $wpdb WordPress database abstraction object.
*/
public function query() {
global $wpdb;

View File

@ -318,6 +318,8 @@ function export_wp( $args = array() ) {
*
* @since 4.6.0
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param WP_Term $term Term object.
*/
function wxr_term_meta( $term ) {

View File

@ -179,6 +179,8 @@ function validate_email( $email, $check_domain = true) {
* @deprecated 3.0.0 Use wp_get_sites()
* @see wp_get_sites()
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param int $start Optional. Offset for retrieving the blog list. Default 0.
* @param int $num Optional. Number of blogs to list. Default 10.
* @param string $deprecated Unused.

View File

@ -1279,6 +1279,8 @@ function wpmu_activate_signup( $key ) {
*
* @since 5.5.0
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param int $id ID of the user to delete.
* @param int|null $reassign ID of the user to reassign posts and links to.
* @param WP_User $user User object.

View File

@ -1033,6 +1033,8 @@ function set_transient( $transient, $value, $expiration = 0 ) {
* The multi-table delete syntax is used to delete the transient record
* from table a, and the corresponding transient_timeout record from table b.
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @since 4.9.0
*
* @param bool $force_db Optional. Force cleanup to run against the database even when an external object cache is used.

View File

@ -7953,6 +7953,8 @@ function wp_add_trashed_suffix_to_post_name_for_trashed_posts( $post_name, $post
* @since 4.5.0
* @access private
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param WP_Post $post The post.
* @return string New slug for the post.
*/

View File

@ -3508,6 +3508,8 @@ function wp_destroy_all_sessions() {
* @since 4.4.0
* @since 4.9.0 The `$site_id` parameter was added to support multisite.
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param int|null $site_id Optional. The site ID to get users with no role for. Defaults to the current site.
* @return string[] Array of user IDs as strings.
*/