Changeset 42761 for trunk/src/wp-includes/class-wp-error.php
- Timestamp:
- 02/27/2018 02:30:46 AM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-error.php
r42343 r42761 72 72 */ 73 73 public function get_error_codes() { 74 if ( empty( $this->errors) ) {74 if ( ! $this->has_errors() ) { 75 75 return array(); 76 76 } … … 163 163 164 164 /** 165 * Verify if the instance contains errors. 166 * 167 * @since 5.0.0 168 * 169 * @return bool 170 */ 171 public function has_errors() { 172 if ( ! empty( $this->errors ) ) { 173 return true; 174 } 175 return false; 176 } 177 178 /** 165 179 * Add an error or append additional message to an existing error. 166 180 *
Note: See TracChangeset
for help on using the changeset viewer.