From 930aa72bc63a22dd32721d5e564d27a1c2fd89fc Mon Sep 17 00:00:00 2001 From: Jonathan Rainville Date: Thu, 14 Jun 2018 16:57:38 -0400 Subject: [PATCH] revert original changes, sorry Ramos --- lib/contracts/compiler.js | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/lib/contracts/compiler.js b/lib/contracts/compiler.js index 9a7778e5..e6c4fc23 100644 --- a/lib/contracts/compiler.js +++ b/lib/contracts/compiler.js @@ -16,16 +16,13 @@ class Compiler { let pluginCompilers = self.plugins.getPluginsProperty('compilers', 'compilers'); pluginCompilers.forEach(function (compilerObject) { - if(!available_compilers[compilerObject.extension]){ - available_compilers[compilerObject.extension] = []; - } - available_compilers[compilerObject.extension].push(compilerObject.cb); + available_compilers[compilerObject.extension] = compilerObject.cb; }); let compiledObject = {}; async.eachObject(available_compilers, - function (extension, compilers, callback) { + function (extension, compiler, callback) { let matchingFiles = contractFiles.filter(function (file) { let fileMatch = file.filename.match(/\.[0-9a-z]+$/); if (fileMatch && (fileMatch[0] === extension)) { @@ -38,9 +35,6 @@ class Compiler { if (!matchingFiles || !matchingFiles.length) { return callback(); } - - let compiler = compilers[0]; - compiler.call(compiler, matchingFiles, function (err, compileResult) { Object.assign(compiledObject, compileResult); callback(err, compileResult);