Passed
Push — master ( cbefbc...3619f4 )
by Frank
16:49 queued 06:49
created
src/TestUtilities/MessageConsumerTestCase.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
      */
104 104
     private function ensureEventsAreMessages(array $events): array
105 105
     {
106
-        return array_map(function (object $event) {
106
+        return array_map(function(object $event) {
107 107
             return $event instanceof Message ? $event : new Message($event);
108 108
         }, $events);
109 109
     }
Please login to merge, or discard this patch.
src/InMemoryMessageRepository.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
         $lastMessage = null;
48 48
 
49 49
         foreach ($this->messages as $message) {
50
-            if ($id->toString() === $message->aggregateRootId()?->toString()) {
50
+            if ($id->toString() === $message->aggregateRootId() ? ->toString()) {
51 51
                 yield $message;
52 52
                 $lastMessage = $message;
53 53
             }
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
         $lastMessage = null;
62 62
 
63 63
         foreach ($this->messages as $message) {
64
-            if ($id->toString() === $message->aggregateRootId()?->toString()
64
+            if ($id->toString() === $message->aggregateRootId() ? ->toString()
65 65
                 && $message->header(Header::AGGREGATE_ROOT_VERSION) > $aggregateRootVersion) {
66 66
                 yield $message;
67 67
                 $lastMessage = $message;
Please login to merge, or discard this patch.
src/Message.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
     {
18 18
     }
19 19
 
20
-    public function withHeader(string $key, int|string|null|AggregateRootId $value): Message
20
+    public function withHeader(string $key, int | string | null | AggregateRootId $value): Message
21 21
     {
22 22
         $clone = clone $this;
23 23
         $clone->headers[$key] = $value;
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
         return $timeOfRecording;
72 72
     }
73 73
 
74
-    public function header(string $key): int|string|array|AggregateRootId|null
74
+    public function header(string $key): int | string | array | AggregateRootId | null
75 75
     {
76 76
         return $this->headers[$key] ?? null;
77 77
     }
Please login to merge, or discard this patch.
src/AggregateRootWithAggregates.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
     protected function eventRecorder(): EventRecorder
25 25
     {
26 26
         if (null === $this->eventRecorder) {
27
-            $this->eventRecorder = new EventRecorder(fn (object $event) => $this->recordThat($event));
27
+            $this->eventRecorder = new EventRecorder(fn(object $event) => $this->recordThat($event));
28 28
         }
29 29
 
30 30
         return $this->eventRecorder;
Please login to merge, or discard this patch.
src/DecoratingMessageDispatcher.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
     public function dispatch(Message ...$messages): void
14 14
     {
15 15
         $this->dispatcher->dispatch(
16
-            ...array_map(fn (Message $message) => $this->decorator->decorate($message), $messages)
16
+            ...array_map(fn(Message $message) => $this->decorator->decorate($message), $messages)
17 17
         );
18 18
     }
19 19
 }
Please login to merge, or discard this patch.
src/EventSourcedAggregateRootRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
         // of recording.
81 81
         $aggregateRootVersion = $aggregateRootVersion - count($events);
82 82
         $metadata = [Header::AGGREGATE_ROOT_ID => $aggregateRootId];
83
-        $messages = array_map(fn (object $event) => $this->decorator->decorate(new Message(
83
+        $messages = array_map(fn(object $event) => $this->decorator->decorate(new Message(
84 84
             $event,
85 85
             $metadata + [Header::AGGREGATE_ROOT_VERSION => ++$aggregateRootVersion]
86 86
         )), $events);
Please login to merge, or discard this patch.