use filepath again

pull/7/head
0mkar 6 years ago committed by yann300
parent 5e4e96e199
commit c4c90e91b8
  1. 3
      remix-tests/src/compiler.js

@ -41,7 +41,6 @@ function compileFileOrFiles (filename, isDirectory, opts, cb) {
// We should only look into current file if a full file name with path is given
// We should only walk through directory if a directory name is passed
try {
filepath = (isDirectory ? filename : path.dirname(filename))
// walkSync only if it is a directory
fs.walkSync(filepath, foundpath => {
// only process .sol files
@ -69,7 +68,7 @@ function compileFileOrFiles (filename, isDirectory, opts, cb) {
compiler.event.register('compilationFinished', this, function (success, data, source) {
next(null, data)
})
compiler.compile(sources, false)
compiler.compile(sources, filepath)
}
], function (err, result) {
let errors = (result.errors || []).filter((e) => e.type === 'Error' || e.severity === 'error')

Loading…
Cancel
Save