Skip to content
Browse files

Merge pull request #496 from arse/master

Testing for key existance in basicEntityPersister / getIndividualValue
  • Loading branch information...
2 parents a445793 + 73e6164 commit 57e5fa98733f7a4f507845c6ade41bc16859add7 @guilhermeblanco guilhermeblanco committed
Showing with 5 additions and 1 deletion.
  1. +5 −1 lib/Doctrine/ORM/Persisters/BasicEntityPersister.php
View
6 lib/Doctrine/ORM/Persisters/BasicEntityPersister.php
@@ -1696,7 +1696,11 @@ private function getIndividualValue($value)
$idValues = $class->getIdentifierValues($value);
}
- $value = $idValues[key($idValues)];
+ $key = key($idValues);
+
+ if (null !== $key){
+ $value = $idValues[$key];
+ }
}
return $value;

0 comments on commit 57e5fa9

Please sign in to comment.
Something went wrong with that request. Please try again.