mirror of
https://github.com/ash-project/ash.git
synced 2024-09-19 21:13:10 +12:00
chore: credo fix (#1347)
This commit is contained in:
parent
de2b3d0d4e
commit
bda0c0e0da
1 changed files with 8 additions and 0 deletions
|
@ -1,4 +1,6 @@
|
||||||
defmodule Status do
|
defmodule Status do
|
||||||
|
@moduledoc false
|
||||||
|
|
||||||
use Ash.Type.Enum, values: [:open, :Closed, :NeverHappened, :Always_Was]
|
use Ash.Type.Enum, values: [:open, :Closed, :NeverHappened, :Always_Was]
|
||||||
|
|
||||||
def match("never_happened"), do: {:ok, :NeverHappened}
|
def match("never_happened"), do: {:ok, :NeverHappened}
|
||||||
|
@ -6,6 +8,8 @@ defmodule Status do
|
||||||
end
|
end
|
||||||
|
|
||||||
defmodule DescriptiveEnum do
|
defmodule DescriptiveEnum do
|
||||||
|
@moduledoc false
|
||||||
|
|
||||||
use Ash.Type.Enum,
|
use Ash.Type.Enum,
|
||||||
values: [
|
values: [
|
||||||
{:foo, "Clearly a foo"},
|
{:foo, "Clearly a foo"},
|
||||||
|
@ -17,9 +21,13 @@ defmodule DescriptiveEnum do
|
||||||
end
|
end
|
||||||
|
|
||||||
defmodule StringEnum do
|
defmodule StringEnum do
|
||||||
|
@moduledoc false
|
||||||
|
|
||||||
use Ash.Type.Enum, values: ["foo", "bar", "baz"]
|
use Ash.Type.Enum, values: ["foo", "bar", "baz"]
|
||||||
end
|
end
|
||||||
|
|
||||||
defmodule MixedEnum do
|
defmodule MixedEnum do
|
||||||
|
@moduledoc false
|
||||||
|
|
||||||
use Ash.Type.Enum, values: [:foo, "bar", "baz"]
|
use Ash.Type.Enum, values: [:foo, "bar", "baz"]
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue