fix mandatory flattening on contract compile

pull/3583/head
Joseph Izang 2 years ago committed by Aniket
parent 27b67847b2
commit d79177f977
  1. 4
      apps/remix-ide/src/app/plugins/contractFlattener.tsx

@ -21,7 +21,9 @@ export class ContractFlattener extends Plugin {
onActivation(): void { onActivation(): void {
this.on('solidity', 'compilationFinished', async (file, source, languageVersion, data, input, version) => { this.on('solidity', 'compilationFinished', async (file, source, languageVersion, data, input, version) => {
await this.flattenContract(source, file, data) if(data.sources && Object.keys(data.sources).length > 1) {
await this.flattenContract(source, file, data)
}
}) })
_paq.push(['trackEvent', 'plugin', 'activated', 'contractFlattener']) _paq.push(['trackEvent', 'plugin', 'activated', 'contractFlattener'])
} }

Loading…
Cancel
Save