Преглед изворни кода

Fix new introduced SpotBugs error and warnings

Signed-off-by: Tim Krüger <t@timkrueger.me>
Tim Krüger пре 3 година
родитељ
комит
6f277cbe92

+ 2 - 3
app/src/main/java/com/nextcloud/talk/models/json/chat/ChatShareOCS.java

@@ -30,7 +30,7 @@ import java.util.Objects;
 
 @Parcel
 @JsonObject
-public class ChatShareOCS extends GenericOCS {
+public class ChatShareOCS {
     @JsonField(name = "data")
     public HashMap<String, ChatMessage> data;
 
@@ -67,8 +67,7 @@ public class ChatShareOCS extends GenericOCS {
         final int PRIME = 59;
         int result = 1;
         final Object $data = this.getData();
-        result = result * PRIME + ($data == null ? 43 : $data.hashCode());
-        return result;
+        return result * PRIME + ($data == null ? 43 : $data.hashCode());
     }
 
     public String toString() {

+ 1 - 2
app/src/main/java/com/nextcloud/talk/models/json/chat/ChatShareOverall.java

@@ -66,8 +66,7 @@ public class ChatShareOverall {
         final int PRIME = 59;
         int result = 1;
         final Object $ocs = this.getOcs();
-        result = result * PRIME + ($ocs == null ? 43 : $ocs.hashCode());
-        return result;
+        return result * PRIME + ($ocs == null ? 43 : $ocs.hashCode());
     }
 
     public String toString() {