Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
let bundleVersion;
// NOTE: Webpack will replace BUNDLE_VERSION with a string.
if (typeof BUNDLE_VERSION != "undefined") bundleVersion = BUNDLE_VERSION;
let supplierOptions;
if (config && config.compilers) {
supplierOptions = {
events: config.events,
solcConfig: config.compilers.solc
};
} else {
const { events, compilers } = new Config();
const solcConfig = compilers.solc;
supplierOptions = { events, solcConfig };
}
const supplier = new CompilerSupplier(supplierOptions);
return {
core: pkg.version,
bundle: bundleVersion,
solc: supplier.version
};
};