Browse Source

Remove unnecessary assertion

Issue: SPR-14279
pull/1062/head
Rossen Stoyanchev 9 years ago
parent
commit
1e003a1c90
  1. 8
      spring-messaging/src/main/java/org/springframework/messaging/simp/broker/SimpleBrokerMessageHandler.java

8
spring-messaging/src/main/java/org/springframework/messaging/simp/broker/SimpleBrokerMessageHandler.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-2015 the original author or authors.
* Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -223,12 +223,6 @@ public class SimpleBrokerMessageHandler extends AbstractBrokerMessageHandler { @@ -223,12 +223,6 @@ public class SimpleBrokerMessageHandler extends AbstractBrokerMessageHandler {
return;
}
SimpMessageHeaderAccessor accessor = MessageHeaderAccessor.getAccessor(message, SimpMessageHeaderAccessor.class);
if (accessor == null) {
throw new IllegalStateException(
"No header accessor (not using the SimpMessagingTemplate?): " + message);
}
if (SimpMessageType.MESSAGE.equals(messageType)) {
logMessage(message);
sendMessageToSubscribers(destination, message);

Loading…
Cancel
Save