carlos8f / haredis

High-availability redis in Node.js.
https://npmjs.org/package/haredis
154 stars 21 forks source link

fixed node.status sometimes undefined #21

Closed lcodes closed 10 years ago

lcodes commented 10 years ago

If a node connects before another node finishes its DNS lookup, the 'status' property of the node performing the DNS lookup will still be undefined, causing the 'responded' getter to return an erroneous value.

Moving the call to setStatus() before the DNS lookup fixes the issue.

carlos8f commented 10 years ago

thanks, looks good!

carlos8f commented 10 years ago

published in v0.2.15