Arsnael commented on code in PR #1495:
URL: https://github.com/apache/james-project/pull/1495#discussion_r1143007919


##########
server/data/data-jmap/src/main/java/org/apache/james/jmap/api/change/MailboxChange.java:
##########
@@ -226,7 +226,21 @@ public List<JmapChange> 
fromMailboxACLUpdated(MailboxACLUpdated mailboxACLUpdate
                     .delegated()
                     .build());
 
-            return Stream.concat(Stream.of(ownerChange), shareeChanges)
+            Stream<MailboxChange> deletionChanges = 
mailboxACLUpdated.getAclDiff()
+                .removedEntries()
+                .filter(entry -> 
entry.getKey().getNameType().equals(MailboxACL.NameType.user))
+                .filter(entry -> !entry.getKey().isNegative())
+                .map(entry -> MailboxChange.builder()
+                    .accountId(AccountId.fromString(entry.getKey().getName()))
+                    .state(stateFactory.generate())
+                    .date(now)
+                    .isCountChange(false)
+                    
.destroyed(ImmutableList.of(mailboxACLUpdated.getMailboxId()))

Review Comment:
   Indeed I managed to reproduce your case, now I get it.
   
   Made the change to updated and added your case as a test as well



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to