Skip to content

Commit

Permalink
Fixed Info bug by checking for null or undefined (#109)
Browse files Browse the repository at this point in the history
  • Loading branch information
gal-blockfence committed Nov 20, 2023
1 parent 32664f7 commit a0c13e8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/ContentDecoder.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -198,5 +198,5 @@ function renderAnalysisTab(tab: string, analyzeResult: EngineResponse): React.Re
}

function infoTabIsEmpty(analyzeResult: EngineResponse, descriptionResultAsync?: UseAsyncReturn<ChatResponse>): boolean {
return analyzeResult?.data_enrichments?.length == 0 && descriptionResultAsync?.status == 'not-requested';
return analyzeResult?.data_enrichments?.length == 0 && (descriptionResultAsync == null || descriptionResultAsync?.status == 'not-requested');
}

0 comments on commit a0c13e8

Please sign in to comment.