Tinder / Scarlet

A Retrofit inspired WebSocket client for Kotlin, Java, and Android
Other
3.23k stars 237 forks source link

How to reconnect socket with Hilt #227

Open AsilbekAzimqulov opened 1 year ago

AsilbekAzimqulov commented 1 year ago

Hello, i use library with Hilt and courotuine. So I have state. I need to token for connecting socket. But I used hilt and scarlet object is Singlton. but if I open app first time yet don't login. without token socket could not connect but I use Hilt songlton object and it created when app opened. So then I can not recreate after login. how can I manage this situataion?