Changed type parameter T in NavStateSaver to nullable#1009
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughThe ChangesNullable NavStateSaver support
Estimated code review effort: 2 (Simple) | ~10 minutes Estimated code review effort: 2 (Simple) | ~10 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 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 |
90fbd7e to
01b654c
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In
`@decompose/src/commonMain/kotlin/com/arkivanov/decompose/router/children/NavStateSaver.kt`:
- Around line 50-57: The NavStateSaver serializer overload currently wraps every
state in SerializableContainer even when the saved value is null, but the
serializer passed to NavStateSaver(serializer) is non-null. Update this overload
to handle nullable values by returning null before calling SerializableContainer
in the save lambda, or otherwise narrow the generic so NavStateSaver only
accepts non-null T; use the NavStateSaver and SerializableContainer symbols to
locate the change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: e79bc770-6dbc-44da-bcdf-e728ea42120a
📒 Files selected for processing (2)
decompose/api/decompose.klib.apidecompose/src/commonMain/kotlin/com/arkivanov/decompose/router/children/NavStateSaver.kt
Merge activity
|
01b654c to
75aff7a
Compare

Summary by CodeRabbit
NavStateSavernow supports nullable configuration values.