4ib3r / StompBrokerJS

NodeJS StompBroker
MIT License
35 stars 66 forks source link

Fix encoding binary frames #15

Closed starstuck closed 5 years ago

starstuck commented 6 years ago

Current implementation is sending only binary body, without headers. I am proposing a change, that creates binary frame content with headers.

When working on this, I have noticed that stompServer will try to run JSON.stringify on frame.body, even if it is already a Buffer with serialised JSON. This PR also includes a change that prevents that.