Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

invalidate reconnect #36

Closed
DavidTomic opened this issue Feb 14, 2019 · 5 comments
Closed

invalidate reconnect #36

DavidTomic opened this issue Feb 14, 2019 · 5 comments

Comments

@DavidTomic
Copy link

Hi,

Is there a way to invalidate reconnect?

If a user e.g. performs logout than reconnect should stop.

@WrathChaos
Copy link
Owner

WrathChaos commented Feb 14, 2019

Hello @DavidTomic,
Business logic is all up to you. Library itself does not have any business logic to reconnect or even connect. If you do not want to auto re-connect. Then you just do not need to use "reconnect" function and you can write your own re-connect business logic :) OR you can use the "reconnect" function but still you need to write your own business logic to check user is already logout, or there is a still alive activity. If you cannot make it, please re-open the issue and let's discuss this :)
Have fun!

@DavidTomic
Copy link
Author

Hi,

reconnect feature provided in this lib is good to have because the user can lose internet connection etc. and once back it will auto-reconnect.

But once reconnect is fired there is no way to stop it, even If I explicitly call disconnect.

I think it is a good feature to have stop reconnect feature because of use case I mentioned in above post.

I'll fork this lib and make stop reconnect feature.

Let me know If you want me to make a pull request for this, thank you.

And thank you for this great lib.

@WrathChaos
Copy link
Owner

Hello @DavidTomic,
You can always make a PR :) I would love that. If you're working on it, please let me know.
I really love to add this feature with PR :)
Thank you for using this lib. Really glad to hear that.

@DavidTomic
Copy link
Author

@WrathChaos
Hi, I implemented this in my project, I will make PR asap.

@WrathChaos
Copy link
Owner

@DavidTomic
Hi again, thank you so much. Waiting for the PR :O

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

No branches or pull requests

2 participants