Skip to content

MPNS 1.2.8: Node 0.10.10 Fix

Compare
Choose a tag to compare
@jeffwilcox jeffwilcox released this 02 Jul 20:01
· 25 commits to master since this release

This release contains a fix contributed by @tjunnone. Thank you!

This release is on NPM

npm install mpns

https://npmjs.org/package/mpns

Background

This uses the .resume() method to help make sure that connections do good things. This is a strongly recommended update for current Node build users.

From Tomas:
The message object received in the 'response' event is a stream, and must be consumed since Node.js version 0.10.x before the connection is released back to the pool. From the docs:
If you add a 'response' event handler, then you must consume the data from the response object, either by calling response.read() whenever there is a 'readable' event, or by adding a 'data' handler, or by calling the .resume() method.

This pull requests simply adds the resume method, which fixes my problem.

Associated PR:
#21