Skip to content

Commit b6ac173

Browse files
committed
Revert convert queries
1 parent 749cb06 commit b6ac173

1 file changed

Lines changed: 1 addition & 25 deletions

File tree

src/Database/Database.php

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -6663,32 +6663,8 @@ public function convertQueries(Document $collection, array $queries): array
66636663
}
66646664

66656665
foreach ($attributes as $attribute) {
6666-
foreach ($queries as $index => $query) {
6666+
foreach ($queries as $query) {
66676667
if ($query->getAttribute() === $attribute->getId()) {
6668-
/**
6669-
* Hack test - Remove this:
6670-
*/
6671-
6672-
if($query->getAttribute() === '$sequence'){
6673-
/**
6674-
* Hack for Postgres, since bindParam does not convert '' on int attribute
6675-
*/
6676-
$values = $query->getValues();
6677-
foreach ($values as $valueIndex => $value) {
6678-
// if($value === ''){
6679-
// $values[$valueIndex] = '0';
6680-
// }
6681-
if(empty($value)){
6682-
throw new DatabaseException\Structure('Shmuel tests');
6683-
}
6684-
}
6685-
$query->setValues($values);
6686-
$queries[$index] = $query;
6687-
}
6688-
6689-
/**
6690-
* End test
6691-
*/
66926668
$query->setOnArray($attribute->getAttribute('array', false));
66936669
}
66946670
}

0 commit comments

Comments
 (0)