Skip to content
Snippets Groups Projects
Commit 620308f8 authored by Robert Martin-Legene's avatar Robert Martin-Legene
Browse files

Algunos bugs mas

parent c51a2db8
No related branches found
No related tags found
No related merge requests found
......@@ -152,7 +152,7 @@ module.exports = class Libbfa
// in a TCP stream .
// Writes out data and closes our end of the connection.
// Geth will reply and then close it's end.
socket.end( w3.jsonify(opname,params).valueOf() );
socket.end( JSON.stringify( w3.jsonify(opname,params).valueOf()));
});
socket.on("data", (d) => {
try {
......@@ -170,6 +170,10 @@ module.exports = class Libbfa
err = e;
});
socket.on("close", () => {
if ( result.error && result.error.code && result.error.message )
err = 'Error ' + result.error.code + ": "+ result.error.message;
else
result = result.result;
callback( err, result );
});
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment