mirror of https://github.com/embarklabs/embark.git
use givenProvider instead of currentProvider
This commit is contained in:
parent
cd0fd94386
commit
49d693dc1a
|
@ -5,7 +5,7 @@ __reduce(<%- connectionList %>,function(prev, value, next) {
|
|||
}
|
||||
|
||||
if (value === '$WEB3' && (typeof web3 !== 'undefined' && typeof Web3 !== 'undefined')) {
|
||||
web3.setProvider(web3.currentProvider);
|
||||
web3.setProvider(web3.givenProvider);
|
||||
} else if (value !== '$WEB3' && (typeof Web3 !== 'undefined' && ((typeof web3 === 'undefined') || (typeof web3 !== 'undefined' && (!web3.isConnected || (web3.isConnected && !web3.isConnected())))))) {
|
||||
|
||||
web3.setProvider(new Web3.providers.HttpProvider(value));
|
||||
|
|
Loading…
Reference in New Issue