Skip to content

Commit

Permalink
JAMES-1670 Extract ToRecipientFolder Init Parameters names as constants
Browse files Browse the repository at this point in the history
  • Loading branch information
chibenwa committed Mar 1, 2016
1 parent b341759 commit 7c6a6b6
Showing 1 changed file with 5 additions and 3 deletions.
Expand Up @@ -53,10 +53,12 @@
*/
public class ToRecipientFolder extends GenericMailet {

public static final String FOLDER = "folder";
public static final String CONSUME = "consume";

private MailboxManager mailboxManager;
private SieveRepository sieveRepository;
private UsersRepository usersRepository;

private String folder;
private boolean consume;

Expand Down Expand Up @@ -95,8 +97,8 @@ public void service(Mail mail) throws MessagingException {
@Override
public void init() throws MessagingException {
super.init();
this.folder = getInitParameter("folder", "INBOX");
this.consume = getInitParameter("consume", false);
this.folder = getInitParameter(FOLDER, "INBOX");
this.consume = getInitParameter(CONSUME, false);
sieveMailet = new SieveMailet(usersRepository, mailboxManager, sieveRepository, this.folder);
sieveMailet.init(new MailetConfig() {

Expand Down

0 comments on commit 7c6a6b6

Please sign in to comment.