Skip to content

Commit

Permalink
Update directive type to match spec
Browse files Browse the repository at this point in the history
  • Loading branch information
maartenvanvliet committed Dec 11, 2020
1 parent e24d3ed commit a968eac
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/absinthe/type/built_ins/introspection.ex
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,17 @@ defmodule Absinthe.Type.BuiltIns.Introspection do
object :__directive do
description "Represents a directive"

field :name, :string
field :name, non_null(:string)

field :description, :string

field :is_repeatable, :boolean,
field :is_repeatable, non_null(:boolean),
resolve: fn _, %{source: source} ->
{:ok, source.repeatable}
end

field :args,
type: list_of(:__inputvalue),
type: non_null(list_of(non_null(:__inputvalue))),
resolve: fn _, %{source: source} ->
args =
source.args
Expand Down Expand Up @@ -89,7 +89,7 @@ defmodule Absinthe.Type.BuiltIns.Introspection do
{:ok, Enum.member?(source.locations, :field)}
end

field :locations, list_of(:__directive_location)
field :locations, non_null(list_of(non_null(:__directive_location)))
end

enum :__directive_location,
Expand Down

0 comments on commit a968eac

Please sign in to comment.