diff --git a/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java b/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java index 473637f96..68017c6bb 100644 --- a/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java +++ b/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java @@ -1229,10 +1229,8 @@ public class XMLPersistenceMetaDataParser return; ValueMetaData vmd = fmd; - switch (_strategy) { - case ONE_MANY: - case MANY_MANY: - vmd = fmd.getElement(); + if (_strategy == ONE_MANY || _strategy == MANY_MANY) { + vmd = fmd.getElement(); } for (CascadeType cascade : cascades) { switch (cascade) {