Skip to content

Conversation

@SamakaCD
Copy link

It's pretty easy to get "NetworkCallback was not registered" error when disconnecting from a local network which is unhandled one. The PR handles it and rejects returned promise if it has been thrown.

@aboozaid
Copy link
Owner

Thank you for this pull request. I think the disconnect func will always has an error when there's NetworkCallback registered so it's better to just resolve it silently in catch instead of throwing an error. What do you think?

@SamakaCD
Copy link
Author

Need to investigate why it throws the error. I guess, that's because unregisterNetworkCallback is called once the app connects. Why do we do so instead of bindProcessToNetwork? I understand that there's a good reason for that since bindProcessToNetwork was used previously.

@aboozaid
Copy link
Owner

Need to investigate why it throws the error. I guess, that's because unregisterNetworkCallback is called once the app connects. Why do we do so instead of bindProcessToNetwork? I understand that there's a good reason for that since bindProcessToNetwork was used previously.

Sorry I meant when you don't have a NetworkCallback registered it will always throws an error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants