https://kotlinlang.org logo
Title
j

jasu

07/27/2022, 1:35 PM
I’m using
compose-hilt-navigation
and in one of the screens i’m using BackHandler(onBack = someCall). Somecall is not getting called any idea? inshort: back handler is not working
re-asking! anyone has idea?
o

oianmol

07/28/2022, 5:25 AM
Check for multiple
BackHandler
's ?
t

theapache64

07/28/2022, 5:25 AM
I think it doesn’t have anything to do with Hilt or Navigation. What’s
someCall
?
j

jasu

07/28/2022, 5:26 AM
@oianmol no, its only one backhandler in entire feature
@theapache64 its just a callback stored in variable.
val someCall: () -> Unit = {
    // some work
}
j

jasu

07/28/2022, 5:41 AM
Yeh i see
same way I’ve been doing but there’s some issue, callback is not triggering. Alright man thanks, I’ll see