Commit 4ccdd5b7 authored by 0mkar's avatar 0mkar

require solc for electron

parent beb30535
......@@ -73,7 +73,8 @@ function Compiler (handleImportCall) {
function onInternalCompilerLoaded () {
if (worker === null) {
var compiler
if (typeof (window) === 'undefined') {
var userAgent = navigator.userAgent.toLowerCase()
if (typeof (window) === 'undefined' || userAgent.indexOf(' electron/') > -1) {
compiler = require('solc')
} else {
compiler = solc(window.Module)
......
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