fixed jsonrpc response 0 not handled properly

This commit is contained in:
Marek Kotewicz
2015-02-04 11:23:23 +01:00
parent a0cfa3ca21
commit f3e1797153
5 changed files with 19 additions and 4 deletions

2
dist/ethereum.js vendored
View File

@@ -979,7 +979,7 @@ var isValidResponse = function (response) {
!response.error &&
response.jsonrpc === '2.0' &&
typeof response.id === 'number' &&
(!!response.result || typeof response.result === 'boolean');
response.result !== undefined; // only undefined is not valid json object
};
/// Should be called to create batch payload object