HHH-9330 : orphanRemoval=true does not work in bidirectional relationships (without cascading)

This commit is contained in:
Gail Badner 2014-11-26 15:25:42 -08:00
parent 555e229cc2
commit ef3550eed5
1 changed files with 3 additions and 1 deletions

View File

@ -205,7 +205,9 @@ public class CascadeStyles {
public static final CascadeStyle DELETE_ORPHAN = new BaseCascadeStyle() { public static final CascadeStyle DELETE_ORPHAN = new BaseCascadeStyle() {
@Override @Override
public boolean doCascade(CascadingAction action) { public boolean doCascade(CascadingAction action) {
return action == CascadingActions.DELETE || action == CascadingActions.SAVE_UPDATE; return action == CascadingActions.DELETE ||
action == CascadingActions.SAVE_UPDATE ||
action == CascadingActions.PERSIST_ON_FLUSH;
} }
@Override @Override