Merge branch '5.2.x'
This commit is contained in:
@@ -256,7 +256,7 @@ public class DefaultStompSession implements ConnectionHandlingStompSession {
|
||||
private Message<byte[]> createMessage(StompHeaderAccessor accessor, @Nullable Object payload) {
|
||||
accessor.updateSimpMessageHeadersFromStompHeaders();
|
||||
Message<byte[]> message;
|
||||
if (isEmpty(payload)) {
|
||||
if (StringUtils.isEmpty(payload) || (payload instanceof byte[] && ((byte[]) payload).length == 0)) {
|
||||
message = MessageBuilder.createMessage(EMPTY_PAYLOAD, accessor.getMessageHeaders());
|
||||
}
|
||||
else {
|
||||
@@ -271,10 +271,6 @@ public class DefaultStompSession implements ConnectionHandlingStompSession {
|
||||
return message;
|
||||
}
|
||||
|
||||
private boolean isEmpty(@Nullable Object payload) {
|
||||
return (StringUtils.isEmpty(payload) || (payload instanceof byte[] && ((byte[]) payload).length == 0));
|
||||
}
|
||||
|
||||
private void execute(Message<byte[]> message) {
|
||||
if (logger.isTraceEnabled()) {
|
||||
StompHeaderAccessor accessor = MessageHeaderAccessor.getAccessor(message, StompHeaderAccessor.class);
|
||||
|
||||
Reference in New Issue
Block a user