Skip to content

Upgrading firebase_analytics 4 to 5

Breaking4.0.2 → 5.0.16Breaking2Platform2Changed3Fixed3Other9

BreakingUpgrade verdict

2 breaking changes and 2 platform requirement changes.

  • A deprecated analytics setting method is gone, so any code still calling it will no longer compile.
  • Android-specific code that toggled analytics collection must now use the shared FirebaseAnalytics method instead.
  • You now need Flutter 1.12.13+hotfix.4 or newer to use this package.
  • You now need Flutter 1.10.0 or newer to use this package.
4 items need code or config changes

Dart SDK requirement changed in 5.0.14: >=2.0.0-dev.28.0 <3.0.0 → >=2.0.0 <3.0.0.

Flutter requirement changed in 5.0.11: >=1.5.0 <2.0.0 → >=1.12.13+hotfix.4 <2.0.0.

Breaking2
Removes the deprecated method setMinimumSessionDuration.
setMinimumSessionDuration
Removes FirebaseAnalyticsAndroid.setAnalyticsCollectionEnabled in favor of FirebaseAnalytics.setAnalyticsCollectionEnabled.
FirebaseAnalyticsAndroid.setAnalyticsCollectionEnabledFirebaseAnalytics.setAnalyticsCollectionEnabled
Platform2
Raises the minimum required Flutter SDK version to 1.12.13+hotfix.4.
Bumps the minimum Flutter version to 1.10.0.

Generated by DepDelta from published Dart source. Not mixed with prose notes.

  • removed: method FirebaseAnalyticsAndroid.setAnalyticsCollectionEnabled(bool enabled): Future<void>
  • removed: method FirebaseAnalyticsAndroid.setMinimumSessionDuration(int milliseconds): Future<void>
  • removed: variable firebaseChannel: const MethodChannel