Skip to content

Commit

Permalink
Fixed up extra keys validation
Browse files Browse the repository at this point in the history
  • Loading branch information
acelot committed Sep 12, 2018
1 parent 0674333 commit d166e94
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Struct.php
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ protected function validate(array $newData): void
$extraKeys = array_keys(array_diff_key($newData, $props));
if (!empty($extraKeys)) {
throw new ValidationException(array_map(function ($extraKey) {
return [$extraKey => "Property \"${$extraKey}\" not defined in schema"];
return [$extraKey => "Property \"$extraKey\" not defined in schema"];
}, $extraKeys));
}

Expand Down

0 comments on commit d166e94

Please sign in to comment.