Skip to content

Commit 527f921

Browse files
Fix dart and base.php
1 parent 3c2b401 commit 527f921

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

templates/dart/lib/id.dart.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ class ID {
99
static String _hexTimestamp() {
1010
final now = DateTime.now();
1111
final sec = (now.millisecondsSinceEpoch / 1000).floor();
12-
final usec = now.microsecondsSinceEpoch - secondsSinceEpoch * 1000000;
12+
final usec = now.microsecondsSinceEpoch - sec * 1000000;
1313
return sec.toRadixString(16) +
1414
usec.toRadixString(16).padLeft(5, '0');
1515
}

tests/Base.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -225,11 +225,11 @@ public function testHTTPSuccess(): void
225225
\json_decode($expected, true),
226226
\json_decode($output[$index], true)
227227
);
228-
} else if ($expected == 'unique()') {
229-
$this->assertNotEmpty($output[$i]);
230-
$this->assertIsString($output[$i]);
231-
$this->assertEquals(20, strlen($output[$i]));
232-
$this->assertNotEquals($output[$i], 'unique()');
228+
} elseif ($expected == 'unique()') {
229+
$this->assertNotEmpty($output[$index]);
230+
$this->assertIsString($output[$index]);
231+
$this->assertEquals(20, strlen($output[$index]));
232+
$this->assertNotEquals($output[$index], 'unique()');
233233
} else {
234234
$this->assertEquals($expected, $output[$index]);
235235
}

0 commit comments

Comments
 (0)