Skip to content

fix(sensors_plus): Resolve incorrect cleanup method call#3898

Open
kaismic wants to merge 1 commit into
fluttercommunity:mainfrom
kaismic:patch-1
Open

fix(sensors_plus): Resolve incorrect cleanup method call#3898
kaismic wants to merge 1 commit into
fluttercommunity:mainfrom
kaismic:patch-1

Conversation

@kaismic

@kaismic kaismic commented Jun 23, 2026

Copy link
Copy Markdown

Description

I'm using this plugin in my app, and I was testing my app on iOS and noticed that the console rapidly printed Communicating on a dead channel.
So after debugging, I figured out that FPPMagnetometerStreamHandlerPlus.onCancel was incorrectly calling _motionManager.stopDeviceMotionUpdates() instead of _motionManager.stopMagnetometerUpdates().

Related Issues

Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I titled the PR using Conventional Commits.
  • I did not modify the CHANGELOG.md nor the plugin version in pubspec.yaml files.
  • All existing and new tests are passing.
  • The analyzer (flutter analyze) does not report any problems on my PR.

Breaking Change

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

  • Yes, this is a breaking change (please indicate that with a ! in the title as explained in Conventional Commits).
  • No, this is not a breaking change.

@kaismic kaismic marked this pull request as ready for review June 23, 2026 03:48

@vbuberen vbuberen left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch. Thank you for this contribution. Seems like a leftover after #2250

Ignore failing example builds - it is not related to your changes and will be addressed separately.

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.

2 participants