Skip to content

Commit 1df67af

Browse files
tsteenbeMarcelBochtler
authored andcommitted
fix(web-app-template): Fix webAppRuleViolation.package.id typeError
Evaluator allows policy rule violations without a package see [1], however this case was not supported in the data mapping from `WebAppRuleViolation` to Ant Design table row data. Fixes #9880. [1]: https://github.com/oss-review-toolkit/ort/blob/cc6f09d/model/src/main/kotlin/RuleViolation.kt#L33 Signed-off-by: Thomas Steenbergen <[email protected]>
1 parent cade929 commit 1df67af

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

plugins/reporters/web-app-template/src/components/RuleViolationsTable.jsx

+2-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,8 @@ const RuleViolationsTable = ({ webAppRuleViolations = [], showExcludesColumn = t
5555
isResolved: webAppRuleViolation.isResolved,
5656
key: webAppRuleViolation.key,
5757
message: webAppRuleViolation.message,
58-
packageId: webAppRuleViolation.package.id,
58+
packageId: webAppRuleViolation.package
59+
? webAppRuleViolation.package.id : '',
5960
rule: webAppRuleViolation.rule,
6061
severity: webAppRuleViolation.severity,
6162
severityIndex: webAppRuleViolation.severityIndex,

0 commit comments

Comments
 (0)