Delete collection first

This commit is contained in:
fogelito 2025-01-22 17:35:30 +02:00
parent 758d8496c1
commit ee9bf984c7

View file

@ -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])