Bug 1653690 - do not report failure if a filter tries to move a message to the same folder. r=mkmelin
--HG-- extra : rebase_source : dee245932fa5d4a651d357b524b07cbcd8fde82d
This commit is contained in:
Родитель
3a9123b834
Коммит
e7afc38a77
|
@ -1953,8 +1953,8 @@ NS_IMETHODIMP nsParseNewMailState::ApplyFilterHit(nsIMsgFilter* filter,
|
|||
}
|
||||
}
|
||||
} else {
|
||||
MOZ_LOG(FILTERLOGMODULE, LogLevel::Warning,
|
||||
("(Local) Target folder is the same as source folder"));
|
||||
MOZ_LOG(FILTERLOGMODULE, LogLevel::Info,
|
||||
("(Local) Target folder is the same as source folder, skipping"));
|
||||
rv = NS_OK;
|
||||
}
|
||||
*applyMore = false;
|
||||
|
@ -1997,8 +1997,8 @@ NS_IMETHODIMP nsParseNewMailState::ApplyFilterHit(nsIMsgFilter* filter,
|
|||
} else
|
||||
m_msgCopiedByFilter = true;
|
||||
} else {
|
||||
MOZ_LOG(FILTERLOGMODULE, LogLevel::Warning,
|
||||
("(Local) Target folder is the same as source folder"));
|
||||
MOZ_LOG(FILTERLOGMODULE, LogLevel::Info,
|
||||
("(Local) Target folder is the same as source folder, skipping"));
|
||||
break;
|
||||
}
|
||||
} break;
|
||||
|
|
|
@ -746,8 +746,12 @@ nsresult nsMsgFilterAfterTheFact::ApplyFilter() {
|
|||
case nsMsgFilterAction::CopyToFolder: {
|
||||
nsCString uri;
|
||||
curFolder->GetURI(uri);
|
||||
BREAK_ACTION_IF_FALSE(!uri.Equals(actionTargetFolderUri),
|
||||
"Target folder is the same as source folder");
|
||||
|
||||
if (uri.Equals(actionTargetFolderUri)) {
|
||||
MOZ_LOG(FILTERLOGMODULE, LogLevel::Info,
|
||||
("(Post) Target folder is the same as source folder, skipping"));
|
||||
break;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIMsgFolder> destIFolder;
|
||||
rv = GetOrCreateFolder(actionTargetFolderUri,
|
||||
|
|
Загрузка…
Ссылка в новой задаче