From bfd23665cb5ea0588dbad6d8f8303020096f11d4 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Wed, 1 Mar 2023 18:13:34 +0530 Subject: [PATCH] fix: graphql --- app/controllers/api/graphql.php | 2 +- src/Appwrite/GraphQL/Types/Mapper.php | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/app/controllers/api/graphql.php b/app/controllers/api/graphql.php index bbc382d976..8ee3b5ac47 100644 --- a/app/controllers/api/graphql.php +++ b/app/controllers/api/graphql.php @@ -30,7 +30,7 @@ App::get('/v1/graphql') ->label('sdk.response.model', Response::MODEL_ANY) ->label('abuse-limit', 60) ->label('abuse-time', 60) - ->param('query', '', new Text(0), 'The query to execute.') + ->param('query', '', new Text(0, 0), 'The query to execute.') ->param('operationName', '', new Text(256), 'The name of the operation to execute.', true) ->param('variables', '', new Text(0), 'The JSON encoded variables to use in the query.', true) ->inject('request') diff --git a/src/Appwrite/GraphQL/Types/Mapper.php b/src/Appwrite/GraphQL/Types/Mapper.php index 42bdc4b149..dbcf845420 100644 --- a/src/Appwrite/GraphQL/Types/Mapper.php +++ b/src/Appwrite/GraphQL/Types/Mapper.php @@ -109,9 +109,6 @@ class Mapper 'type' => $parameterType, 'description' => $parameter['description'], ]; - if ($parameter['optional']) { - $params[$name]['defaultValue'] = $parameter['default']; - } } $field = [