Skip to content

Commit 2e09a2c

Browse files
committed
Fix leak in example
1 parent fc6fc14 commit 2e09a2c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

example-client/src/main/java/ua/naiksoftware/stompclientexample/MainActivity.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,14 +118,14 @@ public void connectStomp(View view) {
118118
}
119119

120120
public void sendEchoViaStomp(View v) {
121-
mStompClient.send("/topic/hello-msg-mapping", "Echo STOMP " + mTimeFormat.format(new Date()))
121+
compositeDisposable.add(mStompClient.send("/topic/hello-msg-mapping", "Echo STOMP " + mTimeFormat.format(new Date()))
122122
.compose(applySchedulers())
123123
.subscribe(() -> {
124124
Log.d(TAG, "STOMP echo send successfully");
125125
}, throwable -> {
126126
Log.e(TAG, "Error send STOMP echo", throwable);
127127
toast(throwable.getMessage());
128-
});
128+
}));
129129
}
130130

131131
public void sendEchoViaRest(View v) {

0 commit comments

Comments
 (0)