Opened 8 years ago

Closed 8 years ago

#1941 closed defect (bug) (invalid)

WP_Error empty code parameter

Reported by: zw7's profile zw7 Owned by:
Milestone: Priority: high
Component: General Keywords:


While debugging the function wp_mail i found a problem within WP_Error class.

On the constructor, we ignore $message and $data parameters if $code is empty, yet the php function Exception::getCode() returns 0 if the exception is thrown without a code.

This is the case for the whole phpmailer library and who knows how many others :)

Change History (1)

#1 @Clorith
8 years ago

  • Resolution set to invalid
  • Status changed from new to closed

Hi there, and thanks for the ticket.

Unfortunately, it sounds like you might be trying to submit a ticket for WordPress core, but are currently on the bugtracker for the network instead.

You will want to report this over at

Note: See TracTickets for help on using tickets.