fix(Ash.Calculation): fix return type for load/3 callback. (#384)

This commit is contained in:
James Harton 2022-09-22 16:44:09 +12:00 committed by GitHub
parent 8a32748448
commit 479b09951c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 3 deletions

View file

@ -167,8 +167,6 @@ spark_locals_without_parens = [
tenant: 1, tenant: 1,
through: 1, through: 1,
timeout: 1, timeout: 1,
timestamps: 0,
timestamps: 1,
touches_resources: 1, touches_resources: 1,
trace_name: 1, trace_name: 1,
transaction: 2, transaction: 2,

View file

@ -28,7 +28,7 @@ defmodule Ash.Calculation do
@callback calculate([Ash.Resource.record()], Keyword.t(), map) :: @callback calculate([Ash.Resource.record()], Keyword.t(), map) ::
{:ok, [term]} | [term] | {:error, term} | :unknown {:ok, [term]} | [term] | {:error, term} | :unknown
@callback expression(Keyword.t(), map) :: any @callback expression(Keyword.t(), map) :: any
@callback load(Ash.Query.t(), Keyword.t(), map) :: Keyword.t() @callback load(Ash.Query.t(), Keyword.t(), map) :: atom | [atom] | Keyword.t()
@callback select(Ash.Query.t(), Keyword.t(), map) :: list(atom) @callback select(Ash.Query.t(), Keyword.t(), map) :: list(atom)
@optional_callbacks expression: 2, calculate: 3 @optional_callbacks expression: 2, calculate: 3