diff options
author | Guilhem Moulin <guilhem@fripost.org> | 2015-07-30 01:16:51 +0200 |
---|---|---|
committer | Guilhem Moulin <guilhem@fripost.org> | 2015-07-30 01:27:08 +0200 |
commit | a76acfe7af03ea9087c3c063c315b52109c41f10 (patch) | |
tree | b21a869a746d41e12c4f42e0a1dc0a5db495ee4c /imapsync | |
parent | 0c1aa3921e1736ab29caa9b77e62446c40d9214a (diff) |
Add a $try parameter to create, delete, rename, etc.
And no longer crash when trying to create a mailbox that already exists.
This could happen for instance if list-select-opts contains 'SUBSCRIBE'
and the mailbox is not subscribed on one side.
Diffstat (limited to 'imapsync')
-rwxr-xr-x | imapsync | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -471,7 +471,7 @@ my @MAILBOXES; } my $subscribed = mbx_subscribed('local', $mailbox); $STH_INSERT_MAILBOX->execute($mailbox, $subscribed); - $IMAP->{remote}->{client}->create($mailbox); + $IMAP->{remote}->{client}->create($mailbox, 1); $IMAP->{remote}->{client}->subscribe($mailbox) if $subscribed; $DBH->commit(); } @@ -483,7 +483,7 @@ my @MAILBOXES; } my $subscribed = mbx_subscribed('remote', $mailbox); $STH_INSERT_MAILBOX->execute($mailbox, $subscribed); - $IMAP->{local}->{client}->create($mailbox); + $IMAP->{local}->{client}->create($mailbox, 1); $IMAP->{local}->{client}->subscribe($mailbox) if $subscribed; $DBH->commit(); } |