-
-
Notifications
You must be signed in to change notification settings - Fork 554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Property map serializable type#1250 #1340
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## dev #1340 +/- ##
============================================
+ Coverage 59.48% 59.53% +0.05%
- Complexity 2980 2986 +6
============================================
Files 312 312
Lines 15331 15335 +4
Branches 1561 1561
============================================
+ Hits 9119 9130 +11
+ Misses 5691 5684 -7
Partials 521 521 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, looks good, please check the comment
} | ||
|
||
override fun read(bundle: Bundle) { | ||
bundle.data.forEach { (key) -> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bundle.data is a Map<String, Serializable>
, so forEach { key, value -> ... }
should be possible, in which case bundle.get(key)
can be replaced by just value
and avoid extra value lookups.
Please check the above is true and update if so.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
toValue(bundle.get(key))
has been replaced by toValue(value.toString())
. Using value
directly caused tests to fail. Still avoids the extra lookup from before.
Brilliant, thank you |
Adding SerializableType to PropertyMap to close #1250. Also includes documentation and test case.
@artemijsem