diff --git a/app/controllers/api/storage.php b/app/controllers/api/storage.php index 480f6c63c6..8cfeb5da3b 100644 --- a/app/controllers/api/storage.php +++ b/app/controllers/api/storage.php @@ -93,7 +93,7 @@ App::post('/v1/storage/buckets') $bucketId = $bucketId === 'unique()' ? ID::unique() : $bucketId; // Map aggregate permissions into the multiple permissions they represent. - $permissions = Permission::aggregate($permissions); + $permissions = Permission::aggregate($permissions) ?? []; $compression ??= Compression::NONE; $encryption ??= true; try { @@ -146,7 +146,7 @@ App::post('/v1/storage/buckets') $bucket = $dbForProject->getDocument('buckets', $bucketId); - $dbForProject->createCollection('bucket_' . $bucket->getSequence(), $attributes, $indexes, permissions: $permissions ?? [], documentSecurity: $fileSecurity); + $dbForProject->createCollection('bucket_' . $bucket->getSequence(), $attributes, $indexes, permissions: $permissions, documentSecurity: $fileSecurity); } catch (DuplicateException) { throw new Exception(Exception::STORAGE_BUCKET_ALREADY_EXISTS); } diff --git a/composer.json b/composer.json index 659d6221f7..40740b711f 100644 --- a/composer.json +++ b/composer.json @@ -52,7 +52,7 @@ "utopia-php/cache": "0.13.*", "utopia-php/cli": "0.15.*", "utopia-php/config": "0.2.*", - "utopia-php/database": "0.73.0", + "utopia-php/database": "0.73.*", "utopia-php/detector": "0.1.*", "utopia-php/domains": "0.8.*", "utopia-php/dsn": "0.2.1", diff --git a/composer.lock b/composer.lock index 718dbaf64b..bddc8ec936 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "f4876940be4499bea26a77a036dece4f", + "content-hash": "f152305ec0b90245773867cde288582d", "packages": [ { "name": "adhocore/jwt", @@ -3493,16 +3493,16 @@ }, { "name": "utopia-php/database", - "version": "0.73.0", + "version": "0.73.2", "source": { "type": "git", "url": "https://github.com/utopia-php/database.git", - "reference": "f9b6c587e54069dc64c2d29174ce8a42b7ba6491" + "reference": "68545dfd5d1ac41ca2f4f5a59719b890fcd8f480" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/database/zipball/f9b6c587e54069dc64c2d29174ce8a42b7ba6491", - "reference": "f9b6c587e54069dc64c2d29174ce8a42b7ba6491", + "url": "https://api.github.com/repos/utopia-php/database/zipball/68545dfd5d1ac41ca2f4f5a59719b890fcd8f480", + "reference": "68545dfd5d1ac41ca2f4f5a59719b890fcd8f480", "shasum": "" }, "require": { @@ -3543,9 +3543,9 @@ ], "support": { "issues": "https://github.com/utopia-php/database/issues", - "source": "https://github.com/utopia-php/database/tree/0.73.0" + "source": "https://github.com/utopia-php/database/tree/0.73.2" }, - "time": "2025-07-27T04:10:06+00:00" + "time": "2025-07-29T03:23:04+00:00" }, { "name": "utopia-php/detector", @@ -8239,7 +8239,7 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": {}, + "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, "platform": { diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php index 09b3ee2b35..03148eeb2b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php @@ -85,7 +85,7 @@ class Update extends Action throw new Exception($this->getNotFoundException()); } - $permissions ??= $collection->getPermissions() ?? []; + $permissions ??= $collection->getPermissions(); // Map aggregate permissions into the multiple permissions they represent. $permissions = Permission::aggregate($permissions);