Commit 4a74018a authored by yann300's avatar yann300

fix autocompile

parent e7ca17a9
...@@ -183,12 +183,12 @@ function compileTab (container, appAPI, appEvents, opts) { ...@@ -183,12 +183,12 @@ function compileTab (container, appAPI, appEvents, opts) {
// ----------------- autoCompile ----------------- // ----------------- autoCompile -----------------
var autoCompileInput = compileContainer.querySelector('#autoCompile') var autoCompileInput = compileContainer.querySelector('#autoCompile')
var autoCompile = true
if (appAPI.config.exists('autoCompile')) { if (appAPI.config.exists('autoCompile')) {
var autoCompile = appAPI.config.get('autoCompile') autoCompile = appAPI.config.get('autoCompile')
if (autoCompile) {
autoCompileInput.setAttribute('checked', autoCompile)
}
} }
appAPI.config.set('autoCompile', autoCompile)
autoCompileInput.setAttribute('checked', autoCompile)
autoCompileInput.addEventListener('change', function () { autoCompileInput.addEventListener('change', function () {
appAPI.config.set('autoCompile', autoCompileInput.checked) appAPI.config.set('autoCompile', autoCompileInput.checked)
......
...@@ -12,8 +12,8 @@ function checkCompiledContracts (browser, compiled, callback) { ...@@ -12,8 +12,8 @@ function checkCompiledContracts (browser, compiled, callback) {
return null return null
} else { } else {
var ret = [] var ret = []
for (var c in contracts) { for (var c = 0; c < contracts.length; c++) {
ret.push(contracts[c].innerText) ret.push(contracts[c].querySelector('div').innerHTML)
} }
return ret return ret
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment