mirror of
https://github.com/appwrite/appwrite
synced 2026-05-23 00:49:02 +00:00
Delete collection first
This commit is contained in:
parent
758d8496c1
commit
ee9bf984c7
1 changed files with 2 additions and 2 deletions
|
|
@ -535,6 +535,8 @@ class Databases extends Action
|
|||
$databaseId = $database->getId();
|
||||
$databaseInternalId = $database->getInternalId();
|
||||
|
||||
$dbForProject->deleteCollection('database_' . $databaseInternalId . '_collection_' . $collection->getInternalId());
|
||||
|
||||
/**
|
||||
* Related collections relating to current collection
|
||||
*/
|
||||
|
|
@ -553,8 +555,6 @@ class Databases extends Action
|
|||
}
|
||||
);
|
||||
|
||||
$dbForProject->deleteCollection('database_' . $databaseInternalId . '_collection_' . $collection->getInternalId());
|
||||
|
||||
$this->deleteByGroup('attributes', [
|
||||
Query::equal('databaseInternalId', [$databaseInternalId]),
|
||||
Query::equal('collectionInternalId', [$collectionInternalId])
|
||||
|
|
|
|||
Loading…
Reference in a new issue