You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by bt...@apache.org on 2020/05/04 03:21:20 UTC
[james-project] 01/12: JAMES-2997 JMAP attachments should use
java.util.Objects
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 0b47fd77990b3c27da3cbf88f9c016bb2ec6e7fb
Author: Benoit Tellier <bt...@linagora.com>
AuthorDate: Mon Apr 27 15:10:38 2020 +0700
JAMES-2997 JMAP attachments should use java.util.Objects
---
.../apache/james/jmap/draft/model/Attachment.java | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/server/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/model/Attachment.java b/server/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/model/Attachment.java
index 045b90e..271e442 100644
--- a/server/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/model/Attachment.java
+++ b/server/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/model/Attachment.java
@@ -19,13 +19,13 @@
package org.apache.james.jmap.draft.model;
+import java.util.Objects;
import java.util.Optional;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonPOJOBuilder;
import com.google.common.annotations.VisibleForTesting;
import com.google.common.base.MoreObjects;
-import com.google.common.base.Objects;
import com.google.common.base.Preconditions;
import com.google.common.base.Strings;
@@ -170,21 +170,21 @@ public class Attachment {
public boolean equals(Object obj) {
if (obj instanceof Attachment) {
Attachment other = (Attachment) obj;
- return Objects.equal(blobId, other.blobId)
- && Objects.equal(type, other.type)
- && Objects.equal(name, other.name)
- && Objects.equal(size, other.size)
- && Objects.equal(cid, other.cid)
- && Objects.equal(isInline, other.isInline)
- && Objects.equal(width, other.width)
- && Objects.equal(height, other.height);
+ return Objects.equals(blobId, other.blobId)
+ && Objects.equals(type, other.type)
+ && Objects.equals(name, other.name)
+ && Objects.equals(size, other.size)
+ && Objects.equals(cid, other.cid)
+ && Objects.equals(isInline, other.isInline)
+ && Objects.equals(width, other.width)
+ && Objects.equals(height, other.height);
}
return false;
}
@Override
public int hashCode() {
- return Objects.hashCode(blobId, type, name, size, cid, isInline, width, height);
+ return Objects.hash(blobId, type, name, size, cid, isInline, width, height);
}
@Override
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org