aboutsummaryrefslogtreecommitdiffstats
path: root/packages/web3-wrapper
diff options
context:
space:
mode:
Diffstat (limited to 'packages/web3-wrapper')
-rw-r--r--packages/web3-wrapper/src/web3_wrapper.ts9
1 files changed, 1 insertions, 8 deletions
diff --git a/packages/web3-wrapper/src/web3_wrapper.ts b/packages/web3-wrapper/src/web3_wrapper.ts
index c2754a13e..b79ade278 100644
--- a/packages/web3-wrapper/src/web3_wrapper.ts
+++ b/packages/web3-wrapper/src/web3_wrapper.ts
@@ -49,7 +49,6 @@ export class Web3Wrapper {
private _web3: Web3;
private _txDefaults: Partial<TxData>;
private _jsonRpcRequestId: number;
- private _nodeType: NodeType | undefined;
/**
* Check if an address is a valid Ethereum address
* @param address Address to check
@@ -498,19 +497,13 @@ export class Web3Wrapper {
}
/**
* Returns either NodeType.Geth or NodeType.Ganache depending on the type of
- * the backing Ethereum node. Throws for any other type of node. This
- * function caches the result and so subsequent calls are fast.
+ * the backing Ethereum node. Throws for any other type of node.
*/
public async getNodeTypeAsync(): Promise<NodeType> {
- if (!_.isUndefined(this._nodeType)) {
- return this._nodeType;
- }
const version = await this.getNodeVersionAsync();
if (_.includes(version, uniqueVersionIds.geth)) {
- this._nodeType = NodeType.Geth;
return NodeType.Geth;
} else if (_.includes(version, uniqueVersionIds.ganache)) {
- this._nodeType = NodeType.Ganache;
return NodeType.Ganache;
} else {
throw new Error(`Unknown client version: ${version}`);