Closed shijianqi closed 9 years ago
What change do you mean exactly?
The current code sends the post data as a string, and the length is send over via the Content-Length
header.
It could be the case that Bitstamp failed to respond within 5 seconds which causes a timeout.
Please change:
'Content-Length': data.length -> Buffer.byteLength(post_data),