Ticket #16769: 16769.patch
| File 16769.patch, 590 bytes (added by hakre, 2 years ago) |
|---|
-
wp-includes/class-wp-error.php
18 18 * @package WordPress 19 19 * @since 2.1.0 20 20 */ 21 class WP_Error {21 class WP_Error extends Exception { 22 22 /** 23 23 * Stores the list of errors. 24 24 * … … 56 56 */ 57 57 function WP_Error($code = '', $message = '', $data = '') { 58 58 if ( empty($code) ) 59 return;59 throw new WP_Error( '', 'Code parameter is missing.' ); 60 60 61 61 $this->errors[$code][] = $message; 62 62