Skip to content

Commit

Permalink
Web3 static utils and version method removed otherwise the utils and …
Browse files Browse the repository at this point in the history
…version property does not exists on the inititated web3 object
  • Loading branch information
Samuel Furter committed Jan 15, 2019
1 parent eec73c3 commit cfd9130
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 22 deletions.
20 changes: 2 additions & 18 deletions packages/web3/src/Web3.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ export default class Web3 extends AbstractWeb3Module {
this.eth = new Eth(provider, options);
this.shh = new Shh(provider, options);
this.bzz = new Bzz(provider);
this.utils = Utils;
this.version = version;
}

/**
Expand Down Expand Up @@ -244,24 +246,6 @@ export default class Web3 extends AbstractWeb3Module {
return new ProvidersModuleFactory().createProviderDetector().detect();
}

/**
* Returns the web3 version
*
* @returns {String}
*/
static get version() {
return version;
}

/**
* Returns the utils
*
* @returns {Utils}
*/
static get utils() {
return Utils;
}

/**
* Returns an object with all public web3 modules
*
Expand Down
4 changes: 0 additions & 4 deletions packages/web3/tests/src/Web3Test.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,10 +131,6 @@ describe('Web3Test', () => {
expect(bzzMock.setProvider).toHaveBeenCalledWith('http://localhost');
});

it('calls the static utils property and gets the expected object', () => {
expect(Web3.utils).toEqual(Utils);
});

it('calls the static modules property and gets the expected object', () => {
const modules = Web3.modules;

Expand Down

0 comments on commit cfd9130

Please sign in to comment.