DDC-770 - Commit missing changes to XmlDriver and YamlDriver
This commit is contained in:
parent
187d9289ad
commit
43f8398fbb
@ -87,8 +87,6 @@ class XmlDriver extends AbstractFileDriver
|
||||
'type' => (string)$discrColumn['type'],
|
||||
'length' => (string)$discrColumn['length']
|
||||
));
|
||||
} else {
|
||||
throw MappingException::missingDiscriminatorColumn($className);
|
||||
}
|
||||
|
||||
// Evaluate <discriminator-map...>
|
||||
@ -98,8 +96,6 @@ class XmlDriver extends AbstractFileDriver
|
||||
$map[(string)$discrMapElement['value']] = (string)$discrMapElement['class'];
|
||||
}
|
||||
$metadata->setDiscriminatorMap($map);
|
||||
} else {
|
||||
throw MappingException::missingDiscriminatorMap($className);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -79,15 +79,11 @@ class YamlDriver extends AbstractFileDriver
|
||||
'type' => $discrColumn['type'],
|
||||
'length' => $discrColumn['length']
|
||||
));
|
||||
} else {
|
||||
throw MappingException::missingDiscriminatorColumn($className);
|
||||
}
|
||||
|
||||
// Evaluate discriminatorMap
|
||||
if (isset($element['discriminatorMap'])) {
|
||||
$metadata->setDiscriminatorMap($element['discriminatorMap']);
|
||||
} else {
|
||||
throw MappingException::missingDiscriminatorMap($className);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user