diff --git a/src/Generator/Builder/Class/CreateMethodBuilder.php b/src/Generator/Builder/Class/CreateMethodBuilder.php index 0d59e75..9011d4a 100644 --- a/src/Generator/Builder/Class/CreateMethodBuilder.php +++ b/src/Generator/Builder/Class/CreateMethodBuilder.php @@ -102,6 +102,8 @@ function (Parameter $p) { ->addBody('}'); } + $creator->addBody('/** @psalm-suppress PossiblyNullArgument */'); + if ($this->withCreatorVariadic) { $newStatement = 'new static(...$constructorParams);'; } else {