From 6c9ac29f374035c29edc004efe4a82233308f78c Mon Sep 17 00:00:00 2001 From: Jake Barnby Date: Wed, 21 Sep 2022 19:01:01 +1200 Subject: [PATCH] Fix attribute unpacking --- src/Appwrite/GraphQL/SchemaBuilder.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/Appwrite/GraphQL/SchemaBuilder.php b/src/Appwrite/GraphQL/SchemaBuilder.php index 989af78f18..ec59e4a52d 100644 --- a/src/Appwrite/GraphQL/SchemaBuilder.php +++ b/src/Appwrite/GraphQL/SchemaBuilder.php @@ -226,12 +226,10 @@ class SchemaBuilder foreach ($collections as $collectionId => $attributes) { $objectType = new ObjectType([ 'name' => $collectionId, - 'fields' => [ - "_id" => [ - 'type' => Type::string() - ], - ...$attributes - ], + 'fields' => \array_merge( + ["_id" => ['type' => Type::string()]], + $attributes + ), ]); $attributes = \array_merge( $attributes,