diff --git a/src/Preparator/Error400BadTypesPreparator.php b/src/Preparator/Error400BadTypesPreparator.php index 142654f..1209ae2 100644 --- a/src/Preparator/Error400BadTypesPreparator.php +++ b/src/Preparator/Error400BadTypesPreparator.php @@ -84,7 +84,7 @@ protected function prepareForBodyFields(Body $body, array $parameters, Operation /** @var Schema $schema */ foreach ($body->getSchema()->properties as $property => $schema) { foreach (self::SCHEMA_TYPES as $type) { - if ($this->isAllowedType($schema->type, $type)) { + if ($this->isAllowedType($schema->type ?? '', $type)) { continue; }