Skip to content

Conversation

@russellwheatley
Copy link
Member

@russellwheatley russellwheatley commented Jan 13, 2022

Description

In retrospect, I don't think we need to track the event channel names at all. In other plugins, we keep a map of stream handlers so we can clean up. In this implementation, we pass a "dispose of" function to the event channel to clean up the stream handler. So the event names aren't used for anything.

So, I think we can remove the queryListeners and associated code. Thoughts, @Salakar?

Will roll out for iOS once I have a second opinion 😄.

Update

Every event stream has a new number id for android & iOS.

Related Issues

fixes #7795
fixes #7556

I suspect it fixes this issue as well: #7618

Checklist

Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]).
This will ensure a smooth and quick review process. Updating the pubspec.yaml and changelogs is not required.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • My PR includes unit or integration tests for all changed/updated/fixed behaviors (See Contributor Guide).
  • All existing and new tests are passing.
  • I updated/added relevant documentation (doc comments with ///).
  • The analyzer (melos run analyze) does not report any problems on my PR.
  • I read and followed the Flutter Style Guide.
  • I signed the CLA.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Does your PR require plugin users to manually update their apps to accommodate your change?

  • Yes, this is a breaking change.
  • No, this is not a breaking change.

@Salakar Salakar added platform: android Issues / PRs which are specifically for Android. platform: ios Issues / PRs which are specifically for iOS. plugin: database labels Jan 18, 2022
@russellwheatley russellwheatley marked this pull request as ready for review January 19, 2022 08:59
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

platform: android Issues / PRs which are specifically for Android. platform: ios Issues / PRs which are specifically for iOS. plugin: database

Projects

None yet

2 participants