diff options
author | Leonid <logvinov.leon@gmail.com> | 2017-06-11 19:52:54 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-06-11 19:52:54 +0800 |
commit | 4ac0ead5ce931871cf12fdaa83d87597bfc9979d (patch) | |
tree | 0813864d3920321e64acadebdacfd1525ea4e998 /src/contract_wrappers/contract_wrapper.ts | |
parent | 4e56c299263cf6a3397a1d7b95fb92a8b61da3c0 (diff) | |
parent | bbe9a811fb28417377ec3d089e0cdd3693480c35 (diff) | |
download | dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.tar dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.tar.gz dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.tar.bz2 dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.tar.lz dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.tar.xz dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.tar.zst dexon-sol-tools-4ac0ead5ce931871cf12fdaa83d87597bfc9979d.zip |
Merge pull request #62 from 0xProject/private
Prefix private vars with _
Diffstat (limited to 'src/contract_wrappers/contract_wrapper.ts')
-rw-r--r-- | src/contract_wrappers/contract_wrapper.ts | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/contract_wrappers/contract_wrapper.ts b/src/contract_wrappers/contract_wrapper.ts index c3067f613..b9426849a 100644 --- a/src/contract_wrappers/contract_wrapper.ts +++ b/src/contract_wrappers/contract_wrapper.ts @@ -5,16 +5,16 @@ import {ZeroExError} from '../types'; import {utils} from '../utils/utils'; export class ContractWrapper { - protected web3Wrapper: Web3Wrapper; + protected _web3Wrapper: Web3Wrapper; constructor(web3Wrapper: Web3Wrapper) { - this.web3Wrapper = web3Wrapper; + this._web3Wrapper = web3Wrapper; } - protected async instantiateContractIfExistsAsync(artifact: Artifact, address?: string): Promise<ContractInstance> { + protected async _instantiateContractIfExistsAsync(artifact: Artifact, address?: string): Promise<ContractInstance> { const c = await contract(artifact); - const providerObj = this.web3Wrapper.getCurrentProvider(); + const providerObj = this._web3Wrapper.getCurrentProvider(); c.setProvider(providerObj); - const networkIdIfExists = await this.web3Wrapper.getNetworkIdIfExistsAsync(); + const networkIdIfExists = await this._web3Wrapper.getNetworkIdIfExistsAsync(); const artifactNetworkConfigs = _.isUndefined(networkIdIfExists) ? undefined : artifact.networks[networkIdIfExists]; @@ -26,7 +26,7 @@ export class ContractWrapper { } if (!_.isUndefined(contractAddress)) { - const doesContractExist = await this.web3Wrapper.doesContractExistAtAddressAsync(contractAddress); + const doesContractExist = await this._web3Wrapper.doesContractExistAtAddressAsync(contractAddress); if (!doesContractExist) { throw new Error(ZeroExError.CONTRACT_DOES_NOT_EXIST); } |