Skip to content

Commit

Permalink
Fix wrong nullability requirement
Browse files Browse the repository at this point in the history
Closes gh-31610
  • Loading branch information
snicoll committed Nov 15, 2023
1 parent ac235a0 commit df6f661
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ public static <T> MessageBuilder<T> withPayload(T payload) {
* @since 4.1
*/
@SuppressWarnings("unchecked")
public static <T> Message<T> createMessage(@Nullable T payload, MessageHeaders messageHeaders) {
public static <T> Message<T> createMessage(T payload, MessageHeaders messageHeaders) {
Assert.notNull(payload, "Payload must not be null");
Assert.notNull(messageHeaders, "MessageHeaders must not be null");
if (payload instanceof Throwable throwable) {
Expand Down

0 comments on commit df6f661

Please sign in to comment.