You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@james.apache.org by bt...@apache.org on 2020/12/05 07:10:24 UTC

[james-project] 17/17: JAMES-3460 Method to check updated flags

This is an automated email from the ASF dual-hosted git repository.

btellier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit 97c577ccfb3be4fdd5c8535f517c5ab5e74b1199
Author: LanKhuat <dl...@linagora.com>
AuthorDate: Thu Dec 3 10:02:21 2020 +0700

    JAMES-3460 Method to check updated flags
---
 .../src/main/java/org/apache/james/mailbox/model/UpdatedFlags.java | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/mailbox/api/src/main/java/org/apache/james/mailbox/model/UpdatedFlags.java b/mailbox/api/src/main/java/org/apache/james/mailbox/model/UpdatedFlags.java
index 650a4b3..1611a63 100644
--- a/mailbox/api/src/main/java/org/apache/james/mailbox/model/UpdatedFlags.java
+++ b/mailbox/api/src/main/java/org/apache/james/mailbox/model/UpdatedFlags.java
@@ -156,7 +156,12 @@ public class UpdatedFlags {
     }
 
     public boolean isUnchanged(Flags.Flag flag) {
-        return !isModifiedToSet(flag) && !isModifiedToUnset(flag);
+        return !isChanged(flag);
+    }
+
+
+    public boolean isChanged(Flags.Flag flag) {
+        return isModifiedToSet(flag) || isModifiedToUnset(flag);
     }
 
     /**


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org