From 6eef5a62340ac46de2b1be975e0ef6dbb3fbdbcc Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Sat, 28 Apr 2018 14:43:36 +0000 Subject: [PATCH] Docs: Correct the possible return types for the `wpdb::query()` method. Props isabel104 See #42505 git-svn-id: https://develop.svn.wordpress.org/trunk@43017 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/wp-db.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/wp-includes/wp-db.php b/src/wp-includes/wp-db.php index 77b64da839..e170ffe959 100644 --- a/src/wp-includes/wp-db.php +++ b/src/wp-includes/wp-db.php @@ -1848,7 +1848,8 @@ class wpdb { * @since 0.71 * * @param string $query Database query - * @return int|false Number of rows affected/selected or false on error + * @return int|bool Boolean true for CREATE, ALTER, TRUNCATE and DROP queries. Number of rows + * affected/selected for all other queries. Boolean false on error. */ public function query( $query ) { if ( ! $this->ready ) {