mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
Validate rich objects passed to SetupResult
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
25c91e6eea
commit
0b58618712
1 changed files with 5 additions and 0 deletions
|
|
@ -26,6 +26,8 @@ declare(strict_types=1);
|
|||
|
||||
namespace OCP\SetupCheck;
|
||||
|
||||
use OCP\RichObjectStrings\IValidator;
|
||||
|
||||
/**
|
||||
* @brief This class is used for storing the result of a setup check
|
||||
*
|
||||
|
|
@ -54,6 +56,9 @@ class SetupResult implements \JsonSerializable {
|
|||
private ?array $descriptionParameters = null,
|
||||
private ?string $linkToDoc = null,
|
||||
) {
|
||||
if ($description !== null && $descriptionParameters !== null) {
|
||||
\OCP\Server::get(IValidator::class)->validate($description, $descriptionParameters);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue