Ticket #5420 (closed enhancement: fixed)
Better exit for wp-mail.php
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 2.5 |
| Component: | General | Version: | 2.3.1 |
| Severity: | minor | Keywords: | has-patch tested |
| Cc: |
Description
Executing wp-mail.php when the POP3 mailbox is empty results in wp_die() and a 500 error. When you run wp-mail.php from the cron tab, it logs the 500 error.
I don't believe it should return an error in this case. The script runs as it should and just doesn't find any data to manipulate like a zero row query. Perhaps a more graceful exit could be considered. Thank you.
Attachments
Change History
-
attachment
wp-mail.diff
added
- Owner changed from anonymous to westi
- Status changed from new to assigned
-
attachment
wp-mail.2.diff
added
Don't issue 500 error if no messages; Check for user/password failure
A user/password failure would look just like there were no messages. New patch checks user/password status and fails with 500 error if either failed. If login is successful and there are no messages, just the 'no messages' message is displayed (no 500 error).
Tested with WP 2.3.1, FreeBSD 6.2-RELEASE-p1, MySQL 4.1.20, with invalid username, invalid password, valid user/pass but no messages, valid user/pass with messages. Works correctly.

Don't return 500 error if no email