Skip to content

Commit 20df5d6

Browse files
authored
Merge pull request #26 from infocyph/feature/update
🔧 refactor(functions.php): Add nullability to UUID function arguments
2 parents 9966868 + 28f0693 commit 20df5d6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/functions.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
* @return string The generated UUID.
1818
* @throws Exception
1919
*/
20-
function uuid1(string $node = null): string
20+
function uuid1(?string $node = null): string
2121
{
2222
return UUID::v1($node);
2323
}
@@ -74,7 +74,7 @@ function uuid5(string $namespace, string $string): string
7474
* @return string
7575
* @throws Exception
7676
*/
77-
function uuid6(string $node = null): string
77+
function uuid6(?string $node = null): string
7878
{
7979
return UUID::v6($node);
8080
}
@@ -89,7 +89,7 @@ function uuid6(string $node = null): string
8989
* @return string
9090
* @throws Exception
9191
*/
92-
function uuid7(?DateTimeInterface $dateTime = null, string $node = null): string
92+
function uuid7(?DateTimeInterface $dateTime = null, ?string $node = null): string
9393
{
9494
return UUID::v7($dateTime, $node);
9595
}
@@ -103,7 +103,7 @@ function uuid7(?DateTimeInterface $dateTime = null, string $node = null): string
103103
* @return string
104104
* @throws Exception
105105
*/
106-
function uuid8(string $node = null): string
106+
function uuid8(?string $node = null): string
107107
{
108108
return UUID::v8($node);
109109
}

0 commit comments

Comments
 (0)