Github user jmesnil commented on a diff in the pull request:
https://github.com/apache/activemq-artemis/pull/1778#discussion_r161789136
--- Diff:
artemis-jms-client/src/main/java/org/apache/activemq/artemis/jms/client/ActiveMQDestination.java
---
@@ -309,7 +330,7 @@ public SimpleString getSimpleAddress() {
}
public String getName() {
- return simpleAddress.toString();
+ return name == null ? simpleAddress.toString() : name.toString();
--- End diff --
if we use `address` instead of `null` when creating an ActiveMQDestination,
we ensure that the fields are always non-null and this method can just return
`name.toString()`
---