Skip to content

Commit

Permalink
fix: return {:ok tuple when upgrading an expression calc to a liter…
Browse files Browse the repository at this point in the history
…al calc
  • Loading branch information
zachdaniel committed May 8, 2024
1 parent fad02ce commit e944274
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions lib/ash/actions/read/calculations.ex
Original file line number Diff line number Diff line change
Expand Up @@ -517,13 +517,14 @@ defmodule Ash.Actions.Read.Calculations do
unknown_on_unknown_refs?: true
) do
{:ok, result} ->
%{
calculation
| module: Ash.Resource.Calculation.Literal,
opts: [value: result],
required_loads: [],
select: []
}
{:ok,
%{
calculation
| module: Ash.Resource.Calculation.Literal,
opts: [value: result],
required_loads: [],
select: []
}}

_ ->
:error
Expand Down

0 comments on commit e944274

Please sign in to comment.