From cd165427039b86757855c935649d369567ed8631 Mon Sep 17 00:00:00 2001 From: Steven Nguyen <1477010+stnguyen90@users.noreply.github.com> Date: Fri, 19 Apr 2024 00:09:48 +0000 Subject: [PATCH] fix(migration): add missing 'apis' attribute to projects collection This change updates the V20 (1.5.x) migration script to create the `apis` attribute in the `projects` collection since it was added to the collections config. --- src/Appwrite/Migration/Version/V20.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Appwrite/Migration/Version/V20.php b/src/Appwrite/Migration/Version/V20.php index 730a9e701..1a599d32f 100644 --- a/src/Appwrite/Migration/Version/V20.php +++ b/src/Appwrite/Migration/Version/V20.php @@ -294,6 +294,13 @@ class V20 extends Migration Console::warning("'oAuthProviders' from {$id}: {$th->getMessage()}"); } + // Create apis attribute + try { + $this->createAttributeFromCollection($this->projectDB, $id, 'apis'); + } catch (Throwable $th) { + Console::warning("'apis' from {$id}: {$th->getMessage()}"); + } + try { $this->projectDB->purgeCachedCollection($id); } catch (Throwable $th) {