updated IMAPHandler.php