diff --git a/lib/Doctrine/ORM/Tools/Export/Driver/PhpExporter.php b/lib/Doctrine/ORM/Tools/Export/Driver/PhpExporter.php index 24f72431e..50236fd12 100644 --- a/lib/Doctrine/ORM/Tools/Export/Driver/PhpExporter.php +++ b/lib/Doctrine/ORM/Tools/Export/Driver/PhpExporter.php @@ -99,6 +99,9 @@ class PhpExporter extends AbstractExporter unset($cascade[$key]); } } + if (count($cascade) === 5) { + $cascade = array('all'); + } $associationMappingArray = array( 'fieldName' => $associationMapping['fieldName'], 'targetEntity' => $associationMapping['targetEntity'],