Skip to content

Commit 8b75ae6

Browse files
committed
Correct example, change .send --> .publish
1 parent d440543 commit 8b75ae6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

_posts/2018-06-29-using-stompjs-v5.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,10 @@ The body of a STOMP message must be a String. If you want to send and receive
263263

264264
```javascript
265265
var quote = { symbol: 'APPL', value: 195.46 };
266-
client.send('/topic/stocks', {}, JSON.stringify(quote));
266+
client.publish({
267+
destination: '/topic/stocks',
268+
body: JSON.stringify(quote),
269+
});
267270

268271
client.subcribe('/topic/stocks', function (message) {
269272
var quote = JSON.parse(message.body);

0 commit comments

Comments
 (0)