HHH-16532 Fix NPE for @Any association fetches
This commit is contained in:
parent
43429d29ed
commit
0aabdb189f
|
@ -887,10 +887,11 @@ public class LoaderSelectBuilder {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if ( loadQueryInfluencers.getEnabledCascadingFetchProfile() != null ) {
|
else if ( loadQueryInfluencers.getEnabledCascadingFetchProfile() != null ) {
|
||||||
final CascadeStyle cascadeStyle = fetchable.asAttributeMapping().getAttributeMetadata()
|
final CascadeStyle cascadeStyle = fetchable.asAttributeMapping() != null ?
|
||||||
.getCascadeStyle();
|
fetchable.asAttributeMapping().getAttributeMetadata().getCascadeStyle() :
|
||||||
final CascadingAction<?> cascadingAction = loadQueryInfluencers.getEnabledCascadingFetchProfile()
|
null;
|
||||||
.getCascadingAction();
|
final CascadingAction<?> cascadingAction =
|
||||||
|
loadQueryInfluencers.getEnabledCascadingFetchProfile().getCascadingAction();
|
||||||
if ( cascadeStyle == null || cascadeStyle.doCascade( cascadingAction ) ) {
|
if ( cascadeStyle == null || cascadeStyle.doCascade( cascadingAction ) ) {
|
||||||
fetchTiming = FetchTiming.IMMEDIATE;
|
fetchTiming = FetchTiming.IMMEDIATE;
|
||||||
// In 5.x the CascadeEntityJoinWalker only join fetched the first collection fetch
|
// In 5.x the CascadeEntityJoinWalker only join fetched the first collection fetch
|
||||||
|
|
Loading…
Reference in New Issue