Refactor programs page to use optional chaining (S6582)#3486
Refactor programs page to use optional chaining (S6582)#3486kasya merged 3 commits intoOWASP:mainfrom
Conversation
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings. WalkthroughReplaced a defensive logical-AND guard on the Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
kasya
left a comment
There was a problem hiding this comment.
@Shubb07 Thanks for updating this!
Could you also update all places where this happens? I believe there 6 files in total
https://sonarcloud.io/project/issues?rules=typescript%3AS6582&issueStatuses=OPEN%2CCONFIRMED&id=OWASP_Nest
|
I just noticed another PR addresses the same issue 👀 but also not all 6 files 😓 |
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3486 +/- ##
=======================================
Coverage ? 85.60%
=======================================
Files ? 461
Lines ? 14221
Branches ? 1893
=======================================
Hits ? 12174
Misses ? 1678
Partials ? 369
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
|
Hey @kasya , I will surely run the make check test next time before raising the pull request. |



Resolves #3467
This PR replaces defensive logical AND checks with optional chaining in the programs page, improving readability and resolving SonarCloud rule typescript:S6582.