Commit 764c5322 authored by Mickaël Guessant's avatar Mickaël Guessant

IMAP: fix regression after #41 IMAP wildcard LIST supportwith unit test

git-svn-id: https://svn.code.sf.net/p/davmail/code/trunk@2467 3d1905a2-6b24-0410-a738-b14d5a86fcbd
parent ed7e6a6d
...@@ -181,7 +181,7 @@ public class ImapConnection extends AbstractConnection { ...@@ -181,7 +181,7 @@ public class ImapConnection extends AbstractConnection {
if ("*%".equals(folderQuery)) { if ("*%".equals(folderQuery)) {
folderQuery = "*"; folderQuery = "*";
} }
boolean wildcard = folderQuery.endsWith("%") && !folderQuery.contains("/"); boolean wildcard = folderQuery.endsWith("%") && !folderQuery.contains("/") && !folderQuery.equals("%");
boolean recursive = folderQuery.endsWith("*") && !folderQuery.startsWith("/public"); boolean recursive = folderQuery.endsWith("*") && !folderQuery.startsWith("/public");
sendSubFolders(command, folderQuery.substring(0, folderQuery.length() - 1), recursive, wildcard); sendSubFolders(command, folderQuery.substring(0, folderQuery.length() - 1), recursive, wildcard);
sendClient(commandId + " OK " + command + " completed"); sendClient(commandId + " OK " + command + " completed");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment