Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.1.3

Bug #16288 getMessagesList breaks if mailbox is empty
Submitted: 2009-06-04 23:34 UTC
From: jeichhor Assigned: doconnor
Status: Closed Package: Net_IMAP (version 1.1.0)
PHP Version: Irrelevant OS:
Roadmaps: (Not assigned)    

 [2009-06-04 23:34 UTC] jeichhor (Jörg Eichhorn)
Description: ------------ when calling getMessagesList() on an empty mailbox - use expunge() to force - it will break PHP Warning: Invalid argument supplied for foreach() in /pear/Net/IMAP.php on line 400 also return value will be undefined/null so far the following fix helped me: $ diff IMAP.php~1~ IMAP.php 399a400,404 > > if (empty($ret['PARSED'])) { > return array(); > } > Expected result: ---------------- getMessagesList() should return an empty array


 [2012-01-02 07:34 UTC] doconnor (Daniel O'Connor)
-Status: Open +Status: Closed -Assigned To: +Assigned To: doconnor
This bug has been fixed in SVN. If this was a documentation problem, the fix will appear on by the end of next Sunday (CET). If this was a problem with the website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.