We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b3823b7 commit 020d57cCopy full SHA for 020d57c
src/Schema/Validator.php
@@ -4,6 +4,7 @@
4
use Gt\Json\JsonKvpObject;
5
use Gt\Json\JsonObject;
6
use Gt\Json\JsonPrimitive\JsonPrimitive;
7
+use JsonSchema\Validator as JsonSchemaValidator;
8
9
class Validator {
10
public function __construct(
@@ -12,7 +13,7 @@ public function __construct(
12
13
14
public function validate(JsonObject $json):ValidationResult {
15
if($this->schema) {
- $validator = new \JsonSchema\Validator();
16
+ $validator = new JsonSchemaValidator();
17
$object = $json instanceof JsonPrimitive
18
? $json->getPrimitiveValue()
19
: $json->asObject();
0 commit comments