Skip to content

Commit

Permalink
fix: Artifact panel crashes when viewing artifacts. Fixes #9391 (#9392)
Browse files Browse the repository at this point in the history
Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>

Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
  • Loading branch information
terrytangyuan committed Aug 18, 2022
1 parent aa23a9e commit 6e8d162
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -57,7 +57,7 @@ export const ArtifactPanel = ({
const artifacts = spec.templates.find(t => t.name === workflow.status.nodes[artifact.nodeId].templateName)?.outputs?.artifacts;
let artifactGCStrategy = '';
if (artifacts !== undefined) {
artifactGCStrategy = artifacts.find(a => a.name === artifact.name).artifactGC?.strategy || spec.artifactGC?.strategy;
artifactGCStrategy = artifacts.find(a => a.name === artifact.name)?.artifactGC?.strategy || spec.artifactGC?.strategy;
}

return (
Expand Down

0 comments on commit 6e8d162

Please sign in to comment.