Skip to content

Commit e5d1cab

Browse files
authored
Merge pull request overblog#734 from overblog/revert-656-mo-olsavmic-patch-1
Revert "Allow to use non-empty constructor for input types"
2 parents f9cd240 + f783f44 commit e5d1cab

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/Transformer/ArgumentsTransformer.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
use GraphQL\Type\Definition\Type;
1313
use Overblog\GraphQLBundle\Error\InvalidArgumentError;
1414
use Overblog\GraphQLBundle\Error\InvalidArgumentsError;
15-
use ReflectionClass;
1615
use Symfony\Component\PropertyAccess\PropertyAccess;
1716
use Symfony\Component\PropertyAccess\PropertyAccessor;
1817
use Symfony\Component\Validator\ConstraintViolationList;
@@ -47,7 +46,7 @@ private function getTypeClassInstance(string $type)
4746
{
4847
$classname = isset($this->classesMap[$type]) ? $this->classesMap[$type]['class'] : false;
4948

50-
return $classname ? (new ReflectionClass($classname))->newInstanceWithoutConstructor() : false;
49+
return $classname ? new $classname() : false;
5150
}
5251

5352
/**

0 commit comments

Comments
 (0)