Skip to content

Commit dfb0a87

Browse files
author
Jérôme Deuchnord
committed
Fix type validation failing for "any" and false-y type wording
1 parent 384f945 commit dfb0a87

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/JsonSchema/Constraints/TypeConstraint.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ protected function implodeWith(array $elements, $delimiter = ', ', $listEnd = fa
134134
*/
135135
protected function validateTypeNameWording($type)
136136
{
137-
if (!isset(self::$wording[$type])) {
137+
if (!array_key_exists($type, self::$wording)) {
138138
throw new StandardUnexpectedValueException(
139139
sprintf(
140140
'No wording for %s available, expected wordings are: [%s]',

0 commit comments

Comments
 (0)