From 7263f080c60608e24252aa06dae90f0d7acd6de1 Mon Sep 17 00:00:00 2001 From: "Chau, Hoang Van" Date: Wed, 25 Dec 2024 16:37:04 +0700 Subject: [PATCH] bugfix/generate-schema-param-array --- src/Parameters/BodyParametersGenerator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Parameters/BodyParametersGenerator.php b/src/Parameters/BodyParametersGenerator.php index 4c5a38c..c11702f 100644 --- a/src/Parameters/BodyParametersGenerator.php +++ b/src/Parameters/BodyParametersGenerator.php @@ -109,7 +109,7 @@ protected function addToProperties(array & $properties, array $nameTokens, array } if ($name === '*') { - if (empty($properties)) { + if (!empty($properties) && !Arr::has($properties, 'properties')) { $propertyObject = $this->createNewPropertyObject($type, $rules); foreach ($propertyObject as $key => $value) { Arr::set($properties, $key, $value);