mirror of
https://github.com/ash-project/ash_graphql.git
synced 2024-09-19 21:03:09 +12:00
fix: don't require attributes that have a default value
This commit is contained in:
parent
24952b2063
commit
fc62c6b8f4
1 changed files with 1 additions and 1 deletions
|
@ -324,7 +324,7 @@ defmodule AshGraphql.Resource do
|
|||
type = field_type(attribute.type, attribute, resource)
|
||||
|
||||
field_type =
|
||||
if attribute.allow_nil? || mutation.type == :update do
|
||||
if attribute.allow_nil? || attribute.default || mutation.type == :update do
|
||||
type
|
||||
else
|
||||
%Absinthe.Blueprint.TypeReference.NonNull{
|
||||
|
|
Loading…
Reference in a new issue