From 38e429827d211c775e2e2b4720f21feedf95f7c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Proch=C3=A1zka?= Date: Tue, 13 Feb 2024 16:19:21 +0100 Subject: [PATCH] Allow setting up target in builder --- src/RecordBuilder.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/RecordBuilder.php b/src/RecordBuilder.php index ee46605..6b14e8f 100644 --- a/src/RecordBuilder.php +++ b/src/RecordBuilder.php @@ -88,6 +88,13 @@ public function withEvent(?string $event): static } + public function withTarget(object $target): static + { + $this->record['target'] = $target; + return $this; + } + + public function withDate(DateTimeInterface $date): static { $this->record['date'] = $date;