Closed chrisandreae closed 6 years ago
Doh! Thanks for the heads up.
@breunigs Do you think it might be possible to get this back on the old behavior?
Oh, sorry about that! I didn't consider this use case, but it makes total sense. There's not even a performance benefit for doing it the way I did. Anyway, patch is in #98.
A fix has been pushed as part of 0.19.1. (Thanks @breunigs!)
Cheers, thanks for the quick fix!
In https://github.com/brandur/json_schema/commit/d110c244b7d3d5121273fa52b636095edbdbac22#diff-50b1d22f09d5badf9130a7c63a618c46R505,
Validator#validate_type
was changed to require strict==
equality for data types rather than the previousis_a?
subtype check.This means that subclasses of the mapped types are no longer accepted. Was this an intended change?
One common use case that this now prevents is ActiveSupport's
HashWithIndifferentAccess
.