From 63a4212f7ea917fdf75eed95bdf5378508371448 Mon Sep 17 00:00:00 2001 From: Florian Schmaus Date: Wed, 30 Oct 2019 08:22:47 +0100 Subject: [PATCH] Remove clone() from DiscoverInfo.Identity there is no need to clone immutable types. --- .../org/jivesoftware/smackx/disco/packet/DiscoverInfo.java | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/smack-extensions/src/main/java/org/jivesoftware/smackx/disco/packet/DiscoverInfo.java b/smack-extensions/src/main/java/org/jivesoftware/smackx/disco/packet/DiscoverInfo.java index 0213d99b8..9c5674f70 100644 --- a/smack-extensions/src/main/java/org/jivesoftware/smackx/disco/packet/DiscoverInfo.java +++ b/smack-extensions/src/main/java/org/jivesoftware/smackx/disco/packet/DiscoverInfo.java @@ -330,7 +330,7 @@ public class DiscoverInfo extends IQ implements DiscoverInfoView, TypedCloneable * attributes. * */ - public static final class Identity implements Comparable, TypedCloneable { + public static final class Identity implements Comparable { private final String category; private final String type; @@ -512,11 +512,6 @@ public class DiscoverInfo extends IQ implements DiscoverInfoView, TypedCloneable } } - @Override - public Identity clone() { - return new Identity(this); - } - @Override public String toString() { return toXML().toString();