Skip to content

Commit fa7e114

Browse files
api: remove unused equals/hashCode from TemplateOVFPropertyResponse
TemplateOVFPropertyResponse is not referenced anywhere outside its own class: nothing keys it in a set or map or compares instances, so its equals()/hashCode() pair has no callers. hashCode() also dereferenced key without a null guard. Remove both methods rather than harden dead code, which also drops the NPE path.
1 parent 2cd8c5e commit fa7e114

1 file changed

Lines changed: 0 additions & 13 deletions

File tree

api/src/main/java/org/apache/cloudstack/api/response/TemplateOVFPropertyResponse.java

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -66,19 +66,6 @@ public class TemplateOVFPropertyResponse extends BaseResponse {
6666
@Param(description = "The ovf property category")
6767
private String category;
6868

69-
@Override
70-
public boolean equals(Object other) {
71-
if (!(other instanceof TemplateOVFPropertyResponse)) {
72-
return false;
73-
}
74-
return key != null && key.equals(((TemplateOVFPropertyResponse)other).key);
75-
}
76-
77-
@Override
78-
public int hashCode() {
79-
return key.hashCode();
80-
}
81-
8269
public String getKey() {
8370
return key;
8471
}

0 commit comments

Comments
 (0)