Skip to content

Commit

Permalink
Remove calls to deprecated ReflectionParameter::getClass().
Browse files Browse the repository at this point in the history
  • Loading branch information
derrabus committed May 23, 2020
1 parent 592b3e0 commit 73e1d0f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion OptionsResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ public function setDefault($option, $value)
return $this;
}

if (isset($params[0]) && null !== ($class = $params[0]->getClass()) && self::class === $class->name && (!isset($params[1]) || (null !== ($class = $params[1]->getClass()) && Options::class === $class->name))) {
if (isset($params[0]) && null !== ($type = $params[0]->getType()) && self::class === $type->getName() && (!isset($params[1]) || (null !== ($type = $params[1]->getType()) && Options::class === $type->getName()))) {
// Store closure for later evaluation
$this->nested[$option][] = $value;
$this->defaults[$option] = [];
Expand Down

0 comments on commit 73e1d0f

Please sign in to comment.