diff options
author | Kate <26026535+provokateurin@users.noreply.github.com> | 2023-03-29 20:47:49 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-29 20:47:49 +0200 |
commit | fc371facd202d7ede86f1adb37fc78a8c478deff (patch) | |
tree | 467bcebf92ef9668c9eb0950d42d6c920822e6f8 | |
parent | 31f4f4117e37849dabbf6b3c83790af878c01119 (diff) | |
parent | b271096495cdcea1b743a572fc73cdb830fbfd25 (diff) | |
download | nextcloud-server-fc371facd202d7ede86f1adb37fc78a8c478deff.tar.gz nextcloud-server-fc371facd202d7ede86f1adb37fc78a8c478deff.zip |
Merge pull request #36667 from nextcloud/fix/ocm-validation-errors
Fix OCM validation errors
-rw-r--r-- | lib/public/Federation/Exceptions/BadRequestException.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/public/Federation/Exceptions/BadRequestException.php b/lib/public/Federation/Exceptions/BadRequestException.php index 8054c0e89f0..bc8b5c7b724 100644 --- a/lib/public/Federation/Exceptions/BadRequestException.php +++ b/lib/public/Federation/Exceptions/BadRequestException.php @@ -32,6 +32,9 @@ use OCP\HintException; * @since 14.0.0 */ class BadRequestException extends HintException { + /** + * @var string[] $parameterList + */ private $parameterList; /** @@ -55,7 +58,7 @@ class BadRequestException extends HintException { * * @since 14.0.0 * - * @return array + * @return array{message: string, validationErrors: array{message: string, name: string}[]} */ public function getReturnMessage() { $result = [ @@ -65,7 +68,7 @@ class BadRequestException extends HintException { ]; foreach ($this->parameterList as $missingParameter) { - $result['validationErrors'] = [ + $result['validationErrors'][] = [ 'name' => $missingParameter, 'message' => 'NOT_FOUND' ]; |