workaround issue on postgres

this is probably a pre-existing hole in the logic,
not related really related to my work
This commit is contained in:
Gavin 2023-04-27 14:06:30 +02:00 committed by Gavin King
parent fb9c007bdd
commit d348ae2d8c

View File

@ -96,7 +96,9 @@ public <T> JdbcLiteralFormatter<T> getJdbcLiteralFormatter(JavaType<T> javaTypeD
}
else {
//noinspection unchecked
elementJavaType = ( (BasicPluralJavaType<T>) javaTypeDescriptor ).getElementJavaType();
elementJavaType = javaTypeDescriptor instanceof BasicPluralJavaType
? ( (BasicPluralJavaType<T>) javaTypeDescriptor ).getElementJavaType()
: null; //TODO: what should really happen here?
}
final JdbcLiteralFormatter<T> elementFormatter = elementJdbcType.getJdbcLiteralFormatter( elementJavaType );
return new JdbcLiteralFormatterArray<>( javaTypeDescriptor, elementFormatter );