Skip to content

Commit a13d0ac

Browse files
committed
HHH-19681 - Fix for issue
Signed-off-by: Jan Schatteman <[email protected]>
1 parent b1411aa commit a13d0ac

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

hibernate-core/src/main/java/org/hibernate/type/descriptor/jdbc/ArrayJdbcType.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,10 @@ protected <T> Object[] getArray(BasicBinder<?> binder, ValueBinder<T> elementBin
170170
protected <X> X getArray(BasicExtractor<X> extractor, java.sql.Array array, WrapperOptions options)
171171
throws SQLException {
172172
final JavaType<X> javaType = extractor.getJavaType();
173-
if ( array != null && getElementJdbcType() instanceof AggregateJdbcType aggregateJdbcType ) {
173+
if (array != null
174+
&& getElementJdbcType() instanceof AggregateJdbcType aggregateJdbcType
175+
&& aggregateJdbcType.getEmbeddableMappingType() != null) {
176+
174177
final EmbeddableMappingType embeddableMappingType = aggregateJdbcType.getEmbeddableMappingType();
175178
final Object rawArray = array.getArray();
176179
final Object[] domainObjects = new Object[Array.getLength( rawArray )];

0 commit comments

Comments
 (0)