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

Ensure live query subscription unsubscribes #1720

Closed
3 tasks done
dplewis opened this issue Feb 1, 2023 · 1 comment · Fixed by #1727
Closed
3 tasks done

Ensure live query subscription unsubscribes #1720

dplewis opened this issue Feb 1, 2023 · 1 comment · Fixed by #1727
Labels
type:feature New feature or improvement of existing feature

Comments

@dplewis
Copy link
Member

dplewis commented Feb 1, 2023

New Feature / Enhancement Checklist

Feature / Enhancement Description

The SDK ensures that live query subscribes successfully with a promise. The same should be applied to unsubscribe. This could be used in the SDK test suite to ensure connections to the server are closed.

Example Use Case

Using a promise would be a breaking change but would be aligned with subscribe

await subscription.unsubscribe();

Using a callback is an alternative

subscription.unsubscribe((error) => {});

Edit: I think we can support both

@parse-github-assistant
Copy link

parse-github-assistant bot commented Feb 1, 2023

Thanks for opening this issue!

  • ❌ Please edit your post and use the provided template when creating a new issue. This helps everyone to understand your post better and asks for essential information to quicker review the issue.

@mtrezza mtrezza added the type:feature New feature or improvement of existing feature label Feb 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:feature New feature or improvement of existing feature
Projects
None yet
2 participants