1
0
mirror of https://github.com/moparisthebest/davmail synced 2024-12-13 03:02:22 -05:00

IMAP: need to include base folder in recursive search, except on root

git-svn-id: http://svn.code.sf.net/p/davmail/code/trunk@1720 3d1905a2-6b24-0410-a738-b14d5a86fcbd
This commit is contained in:
mguessan 2011-06-27 21:58:13 +00:00
parent 8f4bc77c76
commit 9dc774e01b

View File

@ -1098,8 +1098,8 @@ public abstract class ExchangeSession {
public List<Folder> getSubFolders(String folderName, boolean recursive) throws IOException { public List<Folder> getSubFolders(String folderName, boolean recursive) throws IOException {
List<Folder> results = getSubFolders(folderName, or(isEqualTo("folderclass", "IPF.Note"), isNull("folderclass")), List<Folder> results = getSubFolders(folderName, or(isEqualTo("folderclass", "IPF.Note"), isNull("folderclass")),
recursive); recursive);
// need to include base folder in recursive search // need to include base folder in recursive search, except on root
if (recursive) { if (recursive && folderName.length() > 0) {
results.add(getFolder(folderName)); results.add(getFolder(folderName));
} }