From fd3da47e8a8fce10399228f8ec0b0d96c3002870 Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal Date: Thu, 6 Feb 2025 09:55:32 +0000 Subject: [PATCH] chore: added required perms in migrations --- src/Appwrite/Platform/Modules/Storage/Http/Tokens/Update.php | 2 +- src/Appwrite/Platform/Workers/Migrations.php | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Tokens/Update.php b/src/Appwrite/Platform/Modules/Storage/Http/Tokens/Update.php index e9979eb6fc..65430e711f 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Tokens/Update.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Tokens/Update.php @@ -66,7 +66,7 @@ class Update extends Action ->inject('user') ->inject('mode') ->inject('queueForEvents') - ->callback(fn ($tokenId, $expire, $permission, $response, $dbForProject, $queueForEvents) => $this->action($tokenId, $expire, $permission, $response, $dbForProject, $queueForEvents)); + ->callback(fn ($tokenId, $expire, $permissions, $response, $dbForProject, $queueForEvents) => $this->action($tokenId, $expire, $permissions, $response, $dbForProject, $queueForEvents)); } public function action(string $tokenId, ?string $expire, ?array $permissions, Response $response, Database $dbForProject, Event $queueForEvents) diff --git a/src/Appwrite/Platform/Workers/Migrations.php b/src/Appwrite/Platform/Workers/Migrations.php index cd567f6fa3..2d750476fd 100644 --- a/src/Appwrite/Platform/Workers/Migrations.php +++ b/src/Appwrite/Platform/Workers/Migrations.php @@ -226,7 +226,9 @@ class Migrations extends Action 'collections.read', 'collections.write', 'documents.read', - 'documents.write' + 'documents.write', + 'tokens.read', + 'tokens.write', ] ]);