fix filtering of association with custom foreign_key