mirror of
https://github.com/appwrite/appwrite
synced 2026-05-24 09:28:40 +00:00
fix merge leftovers
This commit is contained in:
parent
7e0871d3b6
commit
5f7ff196b1
2 changed files with 9 additions and 8 deletions
|
|
@ -102,7 +102,7 @@ function createAttribute($collectionId, $attribute, $response, $dbForInternal, $
|
||||||
throw new Exception('Attribute limit exceeded', 400);
|
throw new Exception('Attribute limit exceeded', 400);
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
|
|
||||||
// Pass clone of $attribute object to workers
|
// Pass clone of $attribute object to workers
|
||||||
// so we can later modify Document to fit response model
|
// so we can later modify Document to fit response model
|
||||||
|
|
@ -1130,7 +1130,7 @@ App::delete('/v1/database/collections/:collectionId/attributes/:attributeId')
|
||||||
}
|
}
|
||||||
|
|
||||||
$attribute = $dbForInternal->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'deleting'));
|
$attribute = $dbForInternal->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'deleting'));
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
|
|
||||||
$database
|
$database
|
||||||
->setParam('type', DATABASE_TYPE_DELETE_ATTRIBUTE)
|
->setParam('type', DATABASE_TYPE_DELETE_ATTRIBUTE)
|
||||||
|
|
@ -1237,7 +1237,7 @@ App::post('/v1/database/collections/:collectionId/indexes')
|
||||||
throw new Exception('Index already exists', 409);
|
throw new Exception('Index already exists', 409);
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
|
|
||||||
$database
|
$database
|
||||||
->setParam('type', DATABASE_TYPE_CREATE_INDEX)
|
->setParam('type', DATABASE_TYPE_CREATE_INDEX)
|
||||||
|
|
@ -1382,7 +1382,8 @@ App::delete('/v1/database/collections/:collectionId/indexes/:indexId')
|
||||||
}
|
}
|
||||||
|
|
||||||
$index = $dbForInternal->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'deleting'));
|
$index = $dbForInternal->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'deleting'));
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
|
||||||
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
|
|
||||||
$database
|
$database
|
||||||
->setParam('type', DATABASE_TYPE_DELETE_INDEX)
|
->setParam('type', DATABASE_TYPE_DELETE_INDEX)
|
||||||
|
|
|
||||||
|
|
@ -94,7 +94,7 @@ class DatabaseV1 extends Worker
|
||||||
$dbForInternal->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'failed'));
|
$dbForInternal->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'failed'));
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -120,7 +120,7 @@ class DatabaseV1 extends Worker
|
||||||
$dbForInternal->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'failed'));
|
$dbForInternal->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'failed'));
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -150,7 +150,7 @@ class DatabaseV1 extends Worker
|
||||||
$dbForInternal->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'failed'));
|
$dbForInternal->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'failed'));
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -177,6 +177,6 @@ class DatabaseV1 extends Worker
|
||||||
$dbForInternal->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'failed'));
|
$dbForInternal->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'failed'));
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForInternal->purgeDocument('collections', $collectionId);
|
$dbForInternal->deleteCachedDocument('collections', $collectionId);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue