I’m currently refactoring some kotlin code for accessing Android’s archaic App Licensing API to make it more coroutines-friendly. One of the key parts is binding to the licensing service, and I’m wondering the best way to go about this considering that:
1. calling code may try to access this service (
checkLicense
) before
onServiceConnnected
has been called
2. service may need to be reconnected (so cannot just use a