nano-account-crawler
Advanced tools
Comparing version 1.0.24 to 1.0.25
@@ -174,3 +174,3 @@ "use strict"; | ||
case 4: | ||
this.validateIsAccountInfo(response); | ||
this.validateIsAccountInfo(account, response); | ||
return [2 /*return*/, response]; | ||
@@ -233,11 +233,11 @@ } | ||
}; | ||
NanoNode.prototype.validateIsAccountInfo = function (accountInfo) { | ||
NanoNode.prototype.validateIsAccountInfo = function (account, accountInfo) { | ||
if (typeof (accountInfo) !== 'object') { | ||
throw Error("UnexpectedNanoNodeResponse: Unexpected accountInfo. Expected type to be 'object', got: ".concat(typeof (accountInfo))); | ||
throw Error("UnexpectedNanoNodeResponse: Unexpected accountInfo. Expected type to be 'object', got: '".concat(typeof (accountInfo), "' for ").concat(account)); | ||
} | ||
if (accountInfo.hasOwnProperty('error')) { | ||
throw Error("NanoNodeError: ".concat(accountInfo.error)); | ||
throw Error("NanoNodeError: ".concat(accountInfo.error, " for ").concat(account)); | ||
} | ||
if (typeof (accountInfo['confirmation_height']) !== 'string') { | ||
throw Error("UnexpectedNanoNodeResponse: Unexpected accountInfo['confirmation_height']. Expected type to be 'string', got: ".concat(typeof (accountInfo['confirmation_height']))); | ||
throw Error("UnexpectedNanoNodeResponse: Unexpected accountInfo['confirmation_height']. Expected type to be 'string', got: ".concat(typeof (accountInfo['confirmation_height']), " for ").concat(account)); | ||
} | ||
@@ -244,0 +244,0 @@ }; |
{ | ||
"name": "nano-account-crawler", | ||
"version": "1.0.24", | ||
"version": "1.0.25", | ||
"description": "Makes block iterators that make multiple RPC calls to Nano nodes if neccessary. Block confirmation height is checked so only confirmed blocks are iterated.", | ||
@@ -5,0 +5,0 @@ "repository": "https://github.com/Airtune/nano-account-crawler", |
Sorry, the diff of this file is not supported yet
85463