From c60a50288a551d94b118d313fc4fc53ce08e1d21 Mon Sep 17 00:00:00 2001 From: fogelito Date: Thu, 12 Feb 2026 11:24:58 +0200 Subject: [PATCH 1/3] break --- src/Database/Validator/Query/Filter.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Database/Validator/Query/Filter.php b/src/Database/Validator/Query/Filter.php index 6e2e1e5ae..abe2d6c95 100644 --- a/src/Database/Validator/Query/Filter.php +++ b/src/Database/Validator/Query/Filter.php @@ -184,7 +184,7 @@ protected function isValidAttributeAndValues(string $attribute, array $values, s // For dotted attributes on objects, validate as string (path queries) if ($isDottedOnObject) { $validator = new Text(0, 0); - continue 2; + break; } // object containment queries on the base object attribute From 28e1de3cd743ed85edbf41ee84e4bcf7a8f0da20 Mon Sep 17 00:00:00 2001 From: fogelito Date: Thu, 12 Feb 2026 11:35:48 +0200 Subject: [PATCH 2/3] break --- tests/e2e/Adapter/Scopes/ObjectAttributeTests.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php b/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php index e966039ad..30f6c535a 100644 --- a/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php +++ b/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php @@ -1379,6 +1379,16 @@ public function testNestedObjectAttributeEdgeCases(): void ]) ]); + try { + $database->find($collectionId, [ + Query::equal('profile.level1.level2.level3.level4.value', [10]) + ]); + $this->fail('Expected nesting as string'); + } catch (Exception $e) { + $this->assertInstanceOf(QueryException::class, $e); + $this->assertEquals('Invalid query: Query value is invalid for attribute "profile"', $e->getMessage()); + } + $results = $database->find($collectionId, [ Query::equal('profile.level1.level2.level3.level4.value', ['deep_value_1']) ]); From ef60326acd592ba87a32df241e439444ac80ad3f Mon Sep 17 00:00:00 2001 From: fogelito Date: Thu, 12 Feb 2026 13:05:11 +0200 Subject: [PATCH 3/3] Update test --- .../Adapter/Scopes/ObjectAttributeTests.php | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php b/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php index 30f6c535a..aacd0c86f 100644 --- a/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php +++ b/tests/e2e/Adapter/Scopes/ObjectAttributeTests.php @@ -1379,14 +1379,16 @@ public function testNestedObjectAttributeEdgeCases(): void ]) ]); - try { - $database->find($collectionId, [ - Query::equal('profile.level1.level2.level3.level4.value', [10]) - ]); - $this->fail('Expected nesting as string'); - } catch (Exception $e) { - $this->assertInstanceOf(QueryException::class, $e); - $this->assertEquals('Invalid query: Query value is invalid for attribute "profile"', $e->getMessage()); + if ($database->getAdapter()->getSupportForAttributes()) { + try { + $database->find($collectionId, [ + Query::equal('profile.level1.level2.level3.level4.value', [10]) + ]); + $this->fail('Expected nesting as string'); + } catch (Exception $e) { + $this->assertInstanceOf(QueryException::class, $e); + $this->assertEquals('Invalid query: Query value is invalid for attribute "profile"', $e->getMessage()); + } } $results = $database->find($collectionId, [