We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c702cd4 commit ce1f6cfCopy full SHA for ce1f6cf
spring-web/src/main/java/org/springframework/http/DefaultHttpStatusCode.java
@@ -90,16 +90,12 @@ public int hashCode() {
90
91
@Override
92
public boolean equals(Object obj) {
93
- if (obj instanceof HttpStatusCode other) {
94
- return this.value == other.value();
95
- }
96
- else {
97
- return false;
98
+ return (obj instanceof HttpStatusCode other && this.value == other.value());
99
}
100
101
102
public String toString() {
103
return Integer.toString(this.value);
104
+
105
0 commit comments