mirror of
https://github.com/grocy/grocy.git
synced 2025-08-16 18:54:35 +00:00
Fixed API key deletion was not possible (fixes #1203)
This commit is contained in:
@@ -45,6 +45,15 @@ class OpenApiController extends BaseApiController
|
||||
}
|
||||
}
|
||||
|
||||
$spec->components->internalSchemas->ExposedEntity_NotIncludingNotDeletable = clone $spec->components->internalSchemas->StringEnumTemplate;
|
||||
foreach ($spec->components->internalSchemas->ExposedEntity->enum as $value)
|
||||
{
|
||||
if (!in_array($value, $spec->components->internalSchemas->ExposedEntityNoDelete->enum))
|
||||
{
|
||||
array_push($spec->components->internalSchemas->ExposedEntity_NotIncludingNotDeletable->enum, $value);
|
||||
}
|
||||
}
|
||||
|
||||
$spec->components->internalSchemas->ExposedEntity_NotIncludingNotListable = clone $spec->components->internalSchemas->StringEnumTemplate;
|
||||
foreach ($spec->components->internalSchemas->ExposedEntity->enum as $value)
|
||||
{
|
||||
|
Reference in New Issue
Block a user