/** * Checks if the given mailbox exists. * * @param string $mailbox * * @return bool */ public function hasMailBox($mailbox) { return (bool) $this->imap->getMailboxes($this->getImapStream(), $this->getServerString(), $this->getServerSpecification() . $mailbox); }