diff --git a/core/ResponseDefinitions.php b/core/ResponseDefinitions.php index 82421a58039..6f3380bab25 100644 --- a/core/ResponseDefinitions.php +++ b/core/ResponseDefinitions.php @@ -212,6 +212,7 @@ namespace OC\Core; * endedAt: ?int, * allowCleanup: bool, * includeWatermark: bool, + * userFacingErrorMessage: ?string, * } * * @psalm-type CoreProfileAction = array{ diff --git a/lib/public/TaskProcessing/Task.php b/lib/public/TaskProcessing/Task.php index a2899a1f1c9..f0096c42a70 100644 --- a/lib/public/TaskProcessing/Task.php +++ b/lib/public/TaskProcessing/Task.php @@ -295,7 +295,7 @@ final class Task implements \JsonSerializable { } /** - * @psalm-return array{id: int, lastUpdated: int, type: string, status: 'STATUS_CANCELLED'|'STATUS_FAILED'|'STATUS_SUCCESSFUL'|'STATUS_RUNNING'|'STATUS_SCHEDULED'|'STATUS_UNKNOWN', userId: ?string, appId: string, input: array|numeric|string>, output: ?array|numeric|string>, customId: ?string, completionExpectedAt: ?int, progress: ?float, scheduledAt: ?int, startedAt: ?int, endedAt: ?int, allowCleanup: bool, includeWatermark: bool} + * @psalm-return array{id: int, lastUpdated: int, type: string, status: 'STATUS_CANCELLED'|'STATUS_FAILED'|'STATUS_SUCCESSFUL'|'STATUS_RUNNING'|'STATUS_SCHEDULED'|'STATUS_UNKNOWN', userId: ?string, appId: string, input: array|numeric|string>, output: ?array|numeric|string>, customId: ?string, completionExpectedAt: ?int, progress: ?float, scheduledAt: ?int, startedAt: ?int, endedAt: ?int, allowCleanup: bool, includeWatermark: bool, userFacingErrorMessage: ?string} * @since 30.0.0 */ final public function jsonSerialize(): array { @@ -316,6 +316,7 @@ final class Task implements \JsonSerializable { 'endedAt' => $this->getEndedAt(), 'allowCleanup' => $this->getAllowCleanup(), 'includeWatermark' => $this->getIncludeWatermark(), + 'userFacingErrorMessage' => $this->getUserFacingErrorMessage(), ]; }