mirror of
https://github.com/ash-project/ash_double_entry.git
synced 2024-09-19 13:03:19 +12:00
improvement: set context_to_opts
when constructing the query
This commit is contained in:
parent
7c700c4fd2
commit
1fcc2abc37
1 changed files with 1 additions and 1 deletions
|
@ -32,7 +32,7 @@ defmodule AshDoubleEntry.Transfer.Changes.VerifyTransfer do
|
|||
changeset.resource
|
||||
|> AshDoubleEntry.Transfer.Info.transfer_account_resource!()
|
||||
|> Ash.Query.filter(id in ^[from_account_id, to_account_id])
|
||||
|> Ash.Query.for_read(:lock_accounts)
|
||||
|> Ash.Query.for_read(:lock_accounts, context_to_opts(context, authorize?: false))
|
||||
|> Ash.Query.load(balance_as_of_ulid: %{ulid: result.id})
|
||||
|> changeset.api.read!(context_to_opts(context, authorize?: false))
|
||||
|
||||
|
|
Loading…
Reference in a new issue