Skip to content

Commit

Permalink
fix(Ash.Generator): Reuse the changeset actor when calling `bulk_cr…
Browse files Browse the repository at this point in the history
…eate`
  • Loading branch information
sevenseacat committed Jan 9, 2025
1 parent b4747a4 commit b5f4b10
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/ash/generator/generator.ex
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,8 @@ defmodule Ash.Generator do
Ash.bulk_create!(Enum.map(batch, & &1.params), first.resource, first.action.name,
after_action: after_action,
return_records?: true,
return_errors?: true
return_errors?: true,
actor: first.context[:private][:actor]
).records || []

batch ->
Expand Down

0 comments on commit b5f4b10

Please sign in to comment.