do not show undefined property in details

pull/1342/head
lianahus 3 years ago committed by davidzagi93@gmail.com
parent bb90035c9e
commit 1fa6686b7f
  1. 2
      libs/remix-ui/solidity-compiler/src/lib/contract-selection.tsx

@ -115,7 +115,7 @@ export const ContractSelection = (props: ContractSelectionProps) => {
let node let node
if (propertyName === 'web3Deploy' || propertyName === 'name' || propertyName === 'Assembly') { if (propertyName === 'web3Deploy' || propertyName === 'name' || propertyName === 'Assembly') {
node = <pre>{ details[propertyName] }</pre> node = <pre>{ details[propertyName] }</pre>
} else if (propertyName === 'abi' || propertyName === 'metadata') { } else if (details[propertyName] && (propertyName === 'abi' || propertyName === 'metadata')) {
if (details[propertyName] !== '') { if (details[propertyName] !== '') {
try { try {
node = <div> node = <div>

Loading…
Cancel
Save