Issue #2412363 by Arla, zealfire, mgifford, xjm, fago: ComplexDataDefinition::getPropertyDefinition() does not need to check ->propertyDefinitions

8.1.x
Nathaniel Catchpole 2016-02-09 16:41:40 +09:00
parent bb10bfa773
commit f7a24a4651
1 changed files with 3 additions and 5 deletions

View File

@ -28,11 +28,9 @@ abstract class ComplexDataDefinitionBase extends DataDefinition implements Compl
* {@inheritdoc} * {@inheritdoc}
*/ */
public function getPropertyDefinition($name) { public function getPropertyDefinition($name) {
if (!isset($this->propertyDefinitions)) { $definitions = $this->getPropertyDefinitions();
$this->getPropertyDefinitions(); if (isset($definitions[$name])) {
} return $definitions[$name];
if (isset($this->propertyDefinitions[$name])) {
return $this->propertyDefinitions[$name];
} }
} }