Commit 0b5ab22
fix(context): replace unsafe !! map access with error() guard (kotlin:S6611)
DefaultSimulationContext.kt line 856 used !! to access a map value after
a containsKey check, which SonarCloud flags as a potential NPE (kotlin:S6611).
Replace with ?: error(...) to provide a clear message if the invariant is
ever violated.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent bc988ba commit 0b5ab22
1 file changed
Lines changed: 2 additions & 1 deletion
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
853 | 853 | | |
854 | 854 | | |
855 | 855 | | |
856 | | - | |
| 856 | + | |
| 857 | + | |
857 | 858 | | |
858 | 859 | | |
859 | 860 | | |
| |||
0 commit comments