Skip to content

Commit

Permalink
fix(#224): incorrect return type for prepareToRecycleView that change…
Browse files Browse the repository at this point in the history
…d when upgrading to RN 0.76
  • Loading branch information
mateusz1913 committed Feb 9, 2025
1 parent 86787cb commit 36098ee
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,12 @@ class AvoidSoftInputViewManager :
override fun prepareToRecycleView(
reactContext: ThemedReactContext,
view: ReactViewGroup
): ReactViewGroup? {
): ReactViewGroup {
(view as AvoidSoftInputView).cleanup()
return super.prepareToRecycleView(reactContext, view)

super.prepareToRecycleView(reactContext, view)

return view
}

@ReactProp(name = "avoidOffset")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,12 @@ class AvoidSoftInputViewManager : ReactViewManager() {
override fun prepareToRecycleView(
reactContext: ThemedReactContext,
view: ReactViewGroup
): ReactViewGroup? {
): ReactViewGroup {
(view as AvoidSoftInputView).cleanup()
return super.prepareToRecycleView(reactContext, view)

super.prepareToRecycleView(reactContext, view)

return view
}

@ReactProp(name = "avoidOffset")
Expand Down

0 comments on commit 36098ee

Please sign in to comment.