don't compile if no sol extension

pull/3094/head
yann300 6 years ago
parent a5e64d2a64
commit b4a2e824d8
  1. 3
      src/app/tabs/compileTab/compileTab.js

@ -35,7 +35,8 @@ class CompileTab {
this.fileManager.saveCurrentFile() this.fileManager.saveCurrentFile()
this.editor.clearAnnotations() this.editor.clearAnnotations()
var currentFile = this.config.get('currentFile') var currentFile = this.config.get('currentFile')
if (!currentFile && !/.(.sol)$/.exec(currentFile)) return if (!currentFile) return
if (!/\.sol$/.exec(currentFile)) return
// only compile *.sol file. // only compile *.sol file.
var target = currentFile var target = currentFile
var sources = {} var sources = {}

Loading…
Cancel
Save