Permalink
Browse files

Fix imap_reopen 'mailbox not found' error

When this method was called and tried to reopen the imap connection, an
error was thrown because the second argument must be the complete
mailbox path and not only mailbox name
(http://lu.php.net/manual/fr/function.imap-reopen.php).
  • Loading branch information...
1 parent 3f5cd12 commit 8f96aef73c2db22295c7f2f9c3c3925590892ba9 @sherblot committed Oct 4, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/Fetch/Server.php
View
@@ -260,7 +260,7 @@ protected function setImapStream()
{
if(isset($this->imapStream))
{
- if(!imap_reopen($this->imapStream, $this->mailbox, $this->options, 1))
+ if(!imap_reopen($this->imapStream, $this->getServerString(), $this->options, 1))
throw new \RuntimeException(imap_last_error());
}else{
$imapStream = imap_open($this->getServerString(), $this->username, $this->password, $this->options, 1);

0 comments on commit 8f96aef

Please sign in to comment.