Fix execution context change (Web3 & RPC)

pull/1/head
Alex Beregszaszi 8 years ago
parent f9c2dc6469
commit 404b69d3e8
  1. 3
      src/app/execution-context.js

@ -80,12 +80,15 @@ function ExecutionContext () {
setExecutionContextRadio(); setExecutionContextRadio();
} else { } else {
if (context === 'web3') { if (context === 'web3') {
executionContext = context;
setProviderFromEndpoint(); setProviderFromEndpoint();
self.event.trigger('contextChanged', ['web3']); self.event.trigger('contextChanged', ['web3']);
} else if (context === 'injected') { } else if (context === 'injected') {
executionContext = context;
web3.setProvider(injectedProvider); web3.setProvider(injectedProvider);
self.event.trigger('contextChanged', ['injected']); self.event.trigger('contextChanged', ['injected']);
} else if (context === 'vm') { } else if (context === 'vm') {
executionContext = context;
vm.stateManager.revert(function () { vm.stateManager.revert(function () {
vm.stateManager.checkpoint(); vm.stateManager.checkpoint();
}); });

Loading…
Cancel
Save