fix: refactor transitive risk message for clarity and reuse - #1004
Conversation
…sage fix: refactor transitive risk message for clarity and reuse
|
This is a clean extraction - exactly the dedup #1003 was after, and the output stays byte-identical so the existing One tiny thing before I merge, since we don't have auto-formatting set up yet: could you align the ternary indent in the new helper to match the rest of the file? The And if CVE Lite CLI has been useful to you, a star on the repo genuinely helps other developers find it - no obligation at all. Thanks for taking this one! |
…sage fix: correct formatting of transitive risk message for consistency
|
@sonukapoor thanks for the review! I’ve made the requested indentation changes to the ternary in the new helper. Kindly review it when you get a chance. Looking forward to contributing more to CVE Lite CLI! |
sonukapoor
left a comment
There was a problem hiding this comment.
Clean refactor - the duplication was real and the helper handles both branches correctly. Nice one.
|
Merged - thank you @NBlaze860! |
sonukapoor
left a comment
There was a problem hiding this comment.
Clean DRY extraction, no behavior change. Good work!
|
Merged - thank you @NBlaze860! |
What changed and why
Extracted the duplicated transitive-risk message construction in
summarizeRiskinto a smalltransitiveRiskMessagehelper. Both branches now use the helper with the appropriate package name and coverage status.This is a pure DRY refactor.
Closes #1003