1
0
Fork 0
mirror of synced 2024-05-20 12:42:39 +12:00

Apply suggestions from code review

Co-authored-by: Torsten Dittmann <torsten.dittmann@googlemail.com>
This commit is contained in:
Matej Bačo 2021-09-21 20:33:11 +02:00 committed by GitHub
parent d0e777edd5
commit 9c9a17a2a4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -443,7 +443,7 @@ class OpenAPI3 extends Format
if(\is_array($rule['type'])) {
$items = [
'oneOf' => \array_map(function($type) {
'anyOf' => \array_map(function($type) {
return ['$ref' => '#/components/schemas/'.$type];
}, $rule['type'])
];

View file

@ -446,7 +446,7 @@ class Swagger2 extends Format
if(\is_array($rule['type'])) {
$items = [
'oneOf' => \array_map(function($type) {
'anyOf' => \array_map(function($type) {
return ['$ref' => '#/definitions/'.$type];
}, $rule['type'])
];