diff --git a/src/Processors/CleanUnusedComponents.php b/src/Processors/CleanUnusedComponents.php index 56d504fa3..4a7303c32 100644 --- a/src/Processors/CleanUnusedComponents.php +++ b/src/Processors/CleanUnusedComponents.php @@ -38,7 +38,7 @@ protected function cleanup(Analysis $analysis): bool $usedRefs[$annotation->ref] = $annotation->ref; } - foreach (['allOf', 'anyOf', 'oneOff'] as $sub) { + foreach (['allOf', 'anyOf', 'oneOf'] as $sub) { if (property_exists($annotation, $sub) && !Generator::isDefault($annotation->{$sub})) { foreach ($annotation->{$sub} as $subElem) { if (is_object($subElem) && property_exists($subElem, 'ref') && !Generator::isDefault($subElem->ref) && $subElem->ref !== null) { diff --git a/src/Processors/Concerns/CollectorTrait.php b/src/Processors/Concerns/CollectorTrait.php index de5f271c6..2473a4601 100644 --- a/src/Processors/Concerns/CollectorTrait.php +++ b/src/Processors/Concerns/CollectorTrait.php @@ -36,7 +36,7 @@ public function traverse(OA\AbstractAnnotation $annotation): \SplObjectStorage $storage->attach($annotation); - foreach (array_merge($annotation::$_nested, ['allOf', 'anyOf', 'oneOff', 'callbacks']) as $properties) { + foreach (array_merge($annotation::$_nested, ['allOf', 'anyOf', 'oneOf', 'callbacks']) as $properties) { foreach ((array) $properties as $property) { if (isset($annotation->{$property})) { $storage->addAll($this->traverseNested($annotation->{$property}));