mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-10 12:46:46 +00:00
GODT-966 Do nothing if message APPEND to All Mail is already in Archive.
This commit is contained in:
committed by
Jakub Cuth
parent
bb90ed5446
commit
6b7e706100
@ -169,6 +169,10 @@ func (im *imapMailbox) labelExistingMessage(msg storeMessageProvider) error { //
|
||||
// If the message is already in Archive we should not call API at all.
|
||||
// Otherwise the message is already in All mail, Return OK.
|
||||
if pmapi.AllMailLabel == storeMBox.LabelID() {
|
||||
if msg.Message().HasLabelID(pmapi.ArchiveLabel) {
|
||||
return uidplus.AppendResponse(im.storeMailbox.UIDValidity(), im.storeMailbox.GetUIDList([]string{msg.ID()}))
|
||||
}
|
||||
|
||||
foundArchive := false
|
||||
for _, mBox := range im.storeAddress.ListMailboxes() {
|
||||
if mBox.LabelID() == pmapi.ArchiveLabel {
|
||||
|
||||
Reference in New Issue
Block a user