diff --git a/greenmail-core/src/main/java/com/icegreen/greenmail/imap/commands/CopyCommand.java b/greenmail-core/src/main/java/com/icegreen/greenmail/imap/commands/CopyCommand.java index bbe416c8c..ecb12262a 100644 --- a/greenmail-core/src/main/java/com/icegreen/greenmail/imap/commands/CopyCommand.java +++ b/greenmail-core/src/main/java/com/icegreen/greenmail/imap/commands/CopyCommand.java @@ -34,7 +34,7 @@ class CopyCommand extends SelectedStateCommand implements UidEnabledCommand { protected void doProcess(ImapRequestLineReader request, ImapResponse response, ImapSession session) - throws ProtocolException, FolderException { + throws ProtocolException, FolderException { doProcess(request, response, session, false); } @@ -43,7 +43,7 @@ public void doProcess(ImapRequestLineReader request, ImapResponse response, ImapSession session, boolean useUids) - throws ProtocolException, FolderException { + throws ProtocolException, FolderException { IdRange[] idSet = parser.parseIdRange(request); String mailboxName = parser.mailbox(request); parser.endLine(request); @@ -78,25 +78,25 @@ public void doProcess(ImapRequestLineReader request, } session.unsolicitedResponses(response); - response.commandComplete(this, generateCopyUidResponseCode(currentMailbox, copiedUidsOld, copiedUidsNew)); + response.commandComplete(this, generateCopyUidResponseCode(toFolder, copiedUidsOld, copiedUidsNew)); } /** * Generates COPYUID response code * (see http://tools.ietf.org/html/rfc2359) * using format : COPYUID UIDVALIDITY SOURCE-UIDS TARGET-UIDS. - * + *
* For example COPYUID 38505 304,319,320 3956,3957,3958
*
- * @param currentMailbox imap folder which is target of copy command
- * @param copiedUidsFrom List of source uids which was successfully copied
- * @param copiedUidsTo List of message uids which was successfully copied
+ * @param destinationFolder imap folder which is target of copy command
+ * @param copiedUidsFrom List of source uids which was successfully copied
+ * @param copiedUidsTo List of message uids which was successfully copied
* @return response code
*/
- private String generateCopyUidResponseCode(ImapSessionFolder currentMailbox,
- List
- * For example COPYUID 38505 304,319,320 3956,3957,3958
- *
- * @param destinationFolder imap folder which is target of copy command
- * @param copiedUidsFrom List of source uids which was successfully copied
- * @param copiedUidsTo List of message uids which was successfully copied
- * @return response code
- */
- private String generateCopyUidResponseCode(MailFolder destinationFolder,
- List