Skip to content

Commit

Permalink
[frontend] Validate if contracts is null, empty or undefined (#1121)
Browse files Browse the repository at this point in the history
  • Loading branch information
savacano28 authored Jun 28, 2024
1 parent 6f6f545 commit 827af72
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ const CreateInject: FunctionComponent<Props> = ({ title, onCreateInject, isAtomi
<Grid item xs={5} style={{ paddingTop: 10 }}>
<CreateInjectDetails
drawerRef={drawerRef}
contractId={selectedContract !== null ? contracts[selectedContract].injector_contract_id : null}
contractId={selectedContract !== null && contracts?.length ? contracts[selectedContract]?.injector_contract_id : null}
contractContent={selectedContract !== null ? parsedContentContracts[selectedContract] : null}
setSelectedContract={setSelectedContract}
selectedContractKillChainPhase={selectedContractKillChainPhase}
Expand Down

0 comments on commit 827af72

Please sign in to comment.