Update 1.9.x

This commit is contained in:
fogelito
2026-04-06 18:05:38 +03:00
parent c45803b942
commit 66cd5d73db
+1 -13
View File
@@ -589,25 +589,13 @@ Http::post('/v1/migrations/csv/exports')
// Schemaless databases (DocumentsDB, VectorsDB) allow queries on dynamic fields
$isSchemaless = in_array($databaseType, [DATABASE_TYPE_DOCUMENTSDB, DATABASE_TYPE_VECTORSDB]);
// $validator = new Documents(
// attributes: $collection->getAttribute('attributes', []),
// indexes: $collection->getAttribute('indexes', []),
// idAttributeType: $dbForProject->getAdapter()->getIdAttributeType(),
// supportForAttributes: !$isSchemaless,
// );
//
// if (!$validator->isValid($parsedQueries)) {
// throw new Exception(Exception::GENERAL_QUERY_INVALID, $validator->getDescription());
// }
shmuel
$context = new QueryContext();
$context->add($collection);
$validator = new DocumentsValidator(
$context,
idAttributeType: $dbForProject->getAdapter()->getIdAttributeType(),
supportForAttributes: !$isSchemaless,
);
if (!$validator->isValid($parsedQueries)) {