On page pontomail/settings I get the following if no mailbox is set up:
CVS-version

    * warning: imap_open(): Couldn't open stream {:/novalidate-cert}* in /var/www/http/modules/pontomail/IMAPService.inc on line 43.
    * Unable to connect to this server.
      Can't open mailbox {:/novalidate-cert}*: invalid remote specification

4.7-version

    * warning: imap_open(): Couldn't open stream {:/novalidate-cert}* in /var/www/http/modules/pontomail/IMAPService.inc on line 44.

Why does it try to connect, if no servers are specified?
Does it have to connect at all on the settings page?
vg

Comments

sanduhrs’s picture

The message keeps the same after setting up the first mailbox.

warning: imap_open(): Couldn't open stream {:/novalidate-cert}* in /var/www/vhosts/sandbox.erdfisch.de/httpdocs/modules/pontomail/IMAPService.inc on line 44.

Apparently it is trying to connect to an unspecified server, whether or not mailboxes are set up.

mikealpha’s picture

I'm getting the exact same issue. I'm not familiar enough with IMAP to modify the IMAPService.inc in order to eliminate this issue.

sanduhrs’s picture

Allright, I think I got it.
See patch.

sanduhrs’s picture

Status: Active » Needs review

Setting status ;)

Souvent22’s picture

Status: Needs review » Needs work

Hm,

I'm thinking perhaps this check should be in the _pontomail_get_imap_obj function.
I placed a check in _pontomail_get_imap_obj that if it recieves and emapy $sid, it returns a bare imap object.
I did this because if you do not great the object, then you will get errors of "undefined function" else where. I'm going ot take a look also, and see if there is a better way to control this. Also, this function is the only way to connect to and recieve an imap object, so this will also hand and control erros from other functions interacting with the imap object.

Hm, if there are no servers setup, perhaps I just return a form there, and disregard the rest of the code...i'll take a look at it.

Souvent22’s picture

Status: Needs work » Reviewed & tested by the community

Changing status. I believe this should resolve this issue.

Souvent22’s picture

Status: Reviewed & tested by the community » Fixed
Souvent22’s picture

Assigned: Unassigned » Souvent22
Anonymous’s picture

Status: Fixed » Closed (fixed)