Skip to content

Commit fad02ce

Browse files
committed
fix: use positional loading on embedded resources
1 parent 3ac4bc9 commit fad02ce

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/ash/actions/read/read.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1308,7 +1308,7 @@ defmodule Ash.Actions.Read do
13081308
pkey = Ash.Resource.Info.primary_key(original_query.resource)
13091309
# we have to assume they are all there and in the same order. Not my
13101310
# favorite thing, but no way around it in the short term.
1311-
if Enum.empty?(pkey) || missing_pkeys? do
1311+
if Ash.Resource.Info.embedded?(original_query.resource) || Enum.empty?(pkey) || missing_pkeys? do
13121312
Enum.zip_with([data, data_with_selected], fn [record, match] ->
13131313
record
13141314
|> Map.merge(Map.take(match, fields_from_data))

0 commit comments

Comments
 (0)