Skip to content

Commit f5a989f

Browse files
abnegateclaude
andcommitted
fix: resolve PHPStan error and update unit test for non-primary VAR_ID
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 05c5ff8 commit f5a989f

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/Database/Validator/Sequence.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,7 @@ public function isValid($value): bool
5757
case Database::VAR_UUID7:
5858
return \is_string($value) && preg_match('/^[a-f0-9]{8}-[a-f0-9]{4}-7[a-f0-9]{3}-[89ab][a-f0-9]{3}-[a-f0-9]{12}$/i', $value) === 1;
5959
case Database::VAR_INTEGER:
60-
$start = ($this->primary) ? 1 : 0;
61-
$validator = new Range($start, Database::MAX_BIG_INT, Database::VAR_INTEGER);
60+
$validator = new Range(1, Database::MAX_BIG_INT, Database::VAR_INTEGER);
6261
return $validator->isValid($value);
6362

6463
default:

0 commit comments

Comments
 (0)