Skip to content

Commit e194da3

Browse files
authored
Merge pull request #662 from utopia-php/0.71.x
0.71.x
2 parents 33f35f5 + 20998e2 commit e194da3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Database/Database.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5218,7 +5218,7 @@ public function increaseDocumentAttribute(
52185218
int|float|null $max = null
52195219
): Document {
52205220
if ($value <= 0) { // Can be a float
5221-
throw new DatabaseException('Value must be numeric and greater than 0');
5221+
throw new \InvalidArgumentException('Value must be numeric and greater than 0');
52225222
}
52235223

52245224
$collection = $this->silent(fn () => $this->getCollection($collection));
@@ -5315,7 +5315,7 @@ public function decreaseDocumentAttribute(
53155315
int|float|null $min = null
53165316
): Document {
53175317
if ($value <= 0) { // Can be a float
5318-
throw new DatabaseException('Value must be numeric and greater than 0');
5318+
throw new \InvalidArgumentException('Value must be numeric and greater than 0');
53195319
}
53205320

53215321
$collection = $this->silent(fn () => $this->getCollection($collection));

0 commit comments

Comments
 (0)