Closed mctaylorpants closed 4 years ago
The existing patch on PolymorphicArrayValue only handled queries that passed multiple values to a polymorphic type column, for example:
Link.where(source: [source_1, source_2])
In order to handle passing a single value, we need to patch the AssociationQueryHandler.
AssociationQueryHandler
This issue only exists in Rails 5.0 and 5.1; it's been fixed in 5.2.
I've also reorganized the version-specific patches into activerecord_ folders to keep things tidy ✨
activerecord_
✅ This PR passes all the specs in Rails 4, 5.0, 5.1 and 5.2.
The existing patch on PolymorphicArrayValue only handled queries that passed multiple values to a polymorphic type column, for example:
In order to handle passing a single value, we need to patch the
AssociationQueryHandler
.This issue only exists in Rails 5.0 and 5.1; it's been fixed in 5.2.
I've also reorganized the version-specific patches into
activerecord_
folders to keep things tidy ✨✅ This PR passes all the specs in Rails 4, 5.0, 5.1 and 5.2.