Skip to content

Commit

Permalink
removes assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
schmittjoh committed Nov 1, 2018
1 parent 780c859 commit ba6fb37
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Entity/Job.php
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,9 @@ public function findRelatedEntity($class)

public function addRelatedEntity($entity)
{
assert('is_object($entity)');
if ( ! is_object($entity)) {
throw new \RuntimeException(sprintf('$entity must be an object.'));
}

if ($this->relatedEntities->contains($entity)) {
return;
Expand Down

0 comments on commit ba6fb37

Please sign in to comment.