medyas / flutter_qiblah

Flutter Qiblah is a plugin that allows you to display Qiblah direction in you app with support for both Android and iOS.
https://pub.dev/packages/flutter_qiblah
MIT License
127 stars 91 forks source link

Error: The method 'dispose' isn't defined for the class 'FlutterCompass'. #17

Closed iqfareez closed 3 years ago

iqfareez commented 3 years ago

Can't build app due to error. Platform: Android

Log:

Launching lib\main.dart on sdk gphone x86 arm in debug mode...
lib\main.dart:1
/C:/src/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_qiblah-2.0.0/lib/flutter_qiblah.dart:86:22: Error: The method 'dispose' isn't defined for the class 'FlutterCompass'.
 - 'FlutterCompass' is from 'package:flutter_compass/flutter_compass.dart' ('/C:/src/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_compass-0.6.1/lib/flutter_compass.dart').
Try correcting the name to the name of an existing method, or defining a method named 'dispose'.
    FlutterCompass().dispose();
                     ^^^^^^^
3

FAILURE: Build failed with an exception.

* Where:
Script 'C:\src\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1035

* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'C:\src\flutter\bin\flutter.bat'' finished with non-zero exit value 1

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

flutter_qiblah version: 2.0.0 (direct main) flutter_compass version: 0.6.1 (transitive)

iqfareez commented 3 years ago

Solved by upgrade rxdart, flutter_compass etc. https://github.com/iqfareez/flutter_qiblah

medyas commented 3 years ago

if you would make a pull request, will be happy to merge

iqfareez commented 3 years ago

Thanks for your reply. Hope you can check the PR on #18