File tree Expand file tree Collapse file tree 4 files changed +14
-6
lines changed Expand file tree Collapse file tree 4 files changed +14
-6
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ CHANGELOG
4
4
5.2.0
5
5
-----
6
6
7
- * [ BC BREAK] The ` TransportInterface::send() ` and ` AbstractTransport::doSend() ` methods changed to return a ` SentMessage ` instance instead of ` void ` .
7
+ * [ BC BREAK] The ` TransportInterface::send() ` and ` AbstractTransport::doSend() ` methods changed to return a ` ? SentMessage` instance instead of ` void ` .
8
8
9
9
5.1.0
10
10
-----
Original file line number Diff line number Diff line change @@ -48,16 +48,20 @@ public function supports(MessageInterface $message): bool
48
48
return $ this ->transport ->supports ($ message );
49
49
}
50
50
51
- public function send (MessageInterface $ message ): SentMessage
51
+ public function send (MessageInterface $ message ): ? SentMessage
52
52
{
53
53
if (null === $ this ->bus ) {
54
- return $ this ->transport ->send ($ message );
54
+ $ this ->transport ->send ($ message );
55
+
56
+ return null ;
55
57
}
56
58
57
59
if (null !== $ this ->dispatcher ) {
58
60
$ this ->dispatcher ->dispatch (new MessageEvent ($ message , true ));
59
61
}
60
62
61
63
$ this ->bus ->dispatch ($ message );
64
+
65
+ return null ;
62
66
}
63
67
}
Original file line number Diff line number Diff line change @@ -48,16 +48,20 @@ public function supports(MessageInterface $message): bool
48
48
return $ this ->transport ->supports ($ message );
49
49
}
50
50
51
- public function send (MessageInterface $ message ): SentMessage
51
+ public function send (MessageInterface $ message ): ? SentMessage
52
52
{
53
53
if (null === $ this ->bus ) {
54
- return $ this ->transport ->send ($ message );
54
+ $ this ->transport ->send ($ message );
55
+
56
+ return null ;
55
57
}
56
58
57
59
if (null !== $ this ->dispatcher ) {
58
60
$ this ->dispatcher ->dispatch (new MessageEvent ($ message , true ));
59
61
}
60
62
61
63
$ this ->bus ->dispatch ($ message );
64
+
65
+ return null ;
62
66
}
63
67
}
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ interface TransportInterface
25
25
/**
26
26
* @throws TransportExceptionInterface
27
27
*/
28
- public function send (MessageInterface $ message ): SentMessage ;
28
+ public function send (MessageInterface $ message ): ? SentMessage ;
29
29
30
30
public function supports (MessageInterface $ message ): bool ;
31
31
You can’t perform that action at this time.
0 commit comments