Skip to content

Commit

Permalink
Fix type miss matching for the CharSequence
Browse files Browse the repository at this point in the history
  • Loading branch information
skydoves committed Nov 2, 2020
1 parent d1d9762 commit d491110
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ inline fun <reified T : Any> Activity.bundle(
when {
// references
Bundle::class.java.isAssignableFrom(objectType) -> intent.getBundleExtra(key) as? T
CharSequence::class.java.isAssignableFrom(objectType) -> intent.getCharArrayExtra(key) as? T
CharSequence::class.java.isAssignableFrom(objectType) -> intent.getCharSequenceExtra(key) as? T
Parcelable::class.java.isAssignableFrom(objectType) -> intent.getParcelableExtra<Parcelable>(
key
) as? T
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ inline fun <reified T : Any> Fragment.bundle(
when {
// references
Bundle::class.java.isAssignableFrom(objectType) -> arguments?.getBundle(key) as? T
CharSequence::class.java.isAssignableFrom(objectType) -> arguments?.getChar(key) as? T
CharSequence::class.java.isAssignableFrom(objectType) -> arguments?.getCharSequence(key) as? T
Parcelable::class.java.isAssignableFrom(objectType) -> arguments?.getParcelable<Parcelable>(
key
) as? T
Expand Down

0 comments on commit d491110

Please sign in to comment.