diff --git a/src/TrackerRequest.php b/src/TrackerRequest.php index 38927f7..3ffb8d1 100644 --- a/src/TrackerRequest.php +++ b/src/TrackerRequest.php @@ -5,7 +5,6 @@ namespace DragonCode\RequestTracker; use Closure; -use Ramsey\Uuid\UuidFactory; use Symfony\Component\HttpFoundation\Request; use function in_array; @@ -70,7 +69,7 @@ public function getTraceId(): string return $id; } - return (new UuidFactory)->uuid7()->toString(); + return TrackerUuid::get(); } public function custom(string $header, Closure $callback): static diff --git a/src/TrackerUuid.php b/src/TrackerUuid.php new file mode 100644 index 0000000..1b8d8d6 --- /dev/null +++ b/src/TrackerUuid.php @@ -0,0 +1,15 @@ +uuid7()->toString(); + } +}