mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-07 18:56:09 +00:00
[Java][Spring] fix imports for nullable helpers (#10234)
This commit is contained in:
@@ -226,7 +226,7 @@ public class ByteArrayObject {
|
||||
}
|
||||
|
||||
private static <T> boolean equalsNullable(JsonNullable<T> a, JsonNullable<T> b) {
|
||||
return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && a.get().getClass().isArray() ? Arrays.equals((T[])a.get(), (T[])b.get()) : Objects.equals(a.get(), b.get()));
|
||||
return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get()));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -238,9 +238,7 @@ public class ByteArrayObject {
|
||||
if (a == null) {
|
||||
return 1;
|
||||
}
|
||||
return a.isPresent()
|
||||
? (a.get().getClass().isArray() ? Arrays.hashCode((T[])a.get()) : Objects.hashCode(a.get()))
|
||||
: 31;
|
||||
return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user