[GraphQL] hide dossiers brouillon from api
This commit is contained in:
parent
588233d7ec
commit
7a8b1fa639
1 changed files with 1 additions and 1 deletions
|
@ -19,7 +19,7 @@ module Types
|
|||
end
|
||||
|
||||
def dossier(number:)
|
||||
Dossier.for_api_v2.find(number)
|
||||
Dossier.state_not_brouillon.for_api_v2.find(number)
|
||||
rescue => e
|
||||
raise GraphQL::ExecutionError.new(e.message, extensions: { code: :not_found })
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue