Ticket #5420: wp-mail.diff

File wp-mail.diff, 556 bytes (added by Bobcat, 4 years ago)

Don't return 500 error if no email

  • wp-mail.php

     
    1515        wp_die($pop3->ERROR); 
    1616 
    1717$count = $pop3->login(get_option('mailserver_login'), get_option('mailserver_pass')); 
    18 if (0 == $count) wp_die(__('There doesn’t seem to be any new mail.')); 
     18if (0 == $count) { 
     19        $pop3->quit(); 
     20        echo "<p>There doesn't seem to be any new mail.</p>\n"; 
     21        return; 
     22} 
    1923 
    20  
    2124for ($i=1; $i <= $count; $i++) : 
    2225 
    2326        $message = $pop3->get($i);