Skip to content

Commit

Permalink
Temporary fix for crash in focus requester code (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
ankur2136 authored Oct 11, 2023
1 parent 8b7a2e3 commit 39a540e
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,11 @@ fun TogiCountryCodePicker(
)
onValueChange(country.countryPhoneCode to phoneNumber.text, isNumberValid)
keyboardController?.hide()
focusRequester.freeFocus()
try {
focusRequester.freeFocus()
} catch (exception: IllegalStateException) {
Log.e(TAG, "Unable to free focus ${exception.stackTrace}")
}
},
focusRequester = focusRequester,
)
Expand Down

0 comments on commit 39a540e

Please sign in to comment.