Currently it is possible to test an imap connection, but it does not guaranty the retrieval operation would succeed. This function must check that the mailbox can be read (not just opened) by getting the number of emails in the folder. Also, the test must not be done in the validate function, but in its own callback.

CommentFileSizeAuthor
#2 mailhandler_mailbox_test.patch5.56 KBilo

Comments

ilo’s picture

Title: Refacto mailbox test code » Refactor mailbox test code

typo :)

ilo’s picture

Status: Active » Needs review
StatusFileSize
new5.56 KB

This patch removes the mailbox test operation from the form validate handler, providing a custom mailhandler_mailbox_test() function that can be called programatically to verify the mailbox settings.

The patch still keeps the changed values in the form to be able to verify the new settings without saving the mailbox first.

ilo’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.