fix: properly construct nested join relationships

This commit is contained in:
Zach Daniel 2021-12-20 23:12:28 -05:00
parent 5b88f476f2
commit d7874c5ecd

View file

@ -2141,7 +2141,8 @@ defmodule AshPostgres.DataLayer do
source,
filter
) do
join_relationship = Ash.Resource.Info.relationship(source, relationship.join_relationship)
join_relationship =
Ash.Resource.Info.relationship(relationship.source, relationship.join_relationship)
with {:ok, relationship_through} <-
maybe_get_resource_query(relationship.through, join_relationship, query),