Commit b6356b68 authored by chriseth's avatar chriseth Committed by GitHub

Merge pull request #209 from ethereum/worker-error-reporting

Do not hide worker errors in the console
parents ebd130c0 adfb53e8
......@@ -180,8 +180,12 @@ function Compiler (editor, queryParams, handleGithubCall, updateFiles) {
break;
}
});
worker.onerror = function (msg) { console.log(msg.data); };
worker.addEventListener('error', function (msg) { console.log(msg.data); });
worker.onerror = function (msg) {
compilationFinished({ error: 'Worker error: ' + msg.data });
};
worker.addEventListener('error', function (msg) {
compilationFinished({ error: 'Worker error: ' + msg.data });
});
compileJSON = function (source, optimize) {
worker.postMessage({cmd: 'compile', source: JSON.stringify(source), optimize: optimize});
};
......
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