Produce a schema-valid OpenAPI specification (closes #1457)

This commit is contained in:
Bernd Bestel
2021-07-05 23:23:59 +02:00
parent 6462dd8af6
commit 54bf7ed659
10 changed files with 136 additions and 135 deletions

View File

@@ -11,7 +11,7 @@ class FilesApiController extends BaseApiController
{
try
{
if (!in_array($args['group'], $this->getOpenApiSpec()->components->internalSchemas->FileGroups->enum))
if (!in_array($args['group'], $this->getOpenApiSpec()->components->schemas->FileGroups->enum))
{
throw new \Exception('Invalid file group');
}
@@ -39,7 +39,7 @@ class FilesApiController extends BaseApiController
{
try
{
if (!in_array($args['group'], $this->getOpenApiSpec()->components->internalSchemas->FileGroups->enum))
if (!in_array($args['group'], $this->getOpenApiSpec()->components->schemas->FileGroups->enum))
{
throw new \Exception('Invalid file group');
}
@@ -69,7 +69,7 @@ class FilesApiController extends BaseApiController
{
try
{
if (!in_array($args['group'], $this->getOpenApiSpec()->components->internalSchemas->FileGroups->enum))
if (!in_array($args['group'], $this->getOpenApiSpec()->components->schemas->FileGroups->enum))
{
throw new \Exception('Invalid file group');
}
@@ -100,7 +100,7 @@ class FilesApiController extends BaseApiController
{
try
{
if (!in_array($args['group'], $this->getOpenApiSpec()->components->internalSchemas->FileGroups->enum))
if (!in_array($args['group'], $this->getOpenApiSpec()->components->schemas->FileGroups->enum))
{
throw new \Exception('Invalid file group');
}