MAILBOX-357 MailboxAnnotationListener can read MailboxId directly
Project: http://git-wip-us.apache.org/repos/asf/james-project/repo Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/c8d90800 Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/c8d90800 Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/c8d90800 Branch: refs/heads/master Commit: c8d90800d7dbf71321c3bdf6f86aad9e7009043d Parents: 57a0212 Author: Benoit Tellier <[email protected]> Authored: Mon Dec 10 14:22:42 2018 +0700 Committer: Benoit Tellier <[email protected]> Committed: Wed Dec 12 17:50:57 2018 +0700 ---------------------------------------------------------------------- .../james/mailbox/store/event/MailboxAnnotationListener.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/james-project/blob/c8d90800/mailbox/store/src/main/java/org/apache/james/mailbox/store/event/MailboxAnnotationListener.java ---------------------------------------------------------------------- diff --git a/mailbox/store/src/main/java/org/apache/james/mailbox/store/event/MailboxAnnotationListener.java b/mailbox/store/src/main/java/org/apache/james/mailbox/store/event/MailboxAnnotationListener.java index e016361..b64dd6d 100644 --- a/mailbox/store/src/main/java/org/apache/james/mailbox/store/event/MailboxAnnotationListener.java +++ b/mailbox/store/src/main/java/org/apache/james/mailbox/store/event/MailboxAnnotationListener.java @@ -52,11 +52,11 @@ public class MailboxAnnotationListener implements MailboxListener { @Override public void event(Event event) { - if (event instanceof EventFactory.MailboxDeletionImpl) { + if (event instanceof MailboxDeletion) { try { MailboxSession mailboxSession = mailboxManager.createSystemSession(event.getUser().asString()); AnnotationMapper annotationMapper = mailboxSessionMapperFactory.getAnnotationMapper(mailboxSession); - MailboxId mailboxId = ((EventFactory.MailboxDeletionImpl) event).getMailbox().getMailboxId(); + MailboxId mailboxId = ((MailboxDeletion) event).getMailboxId(); deleteRelatedAnnotations(mailboxId, annotationMapper); } catch (MailboxException e) { --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
