Skip to content

Reset Firebase client when Segment is reset #44

Description

@stephen-mojo

I was looking through the implementation of this integration and noticed that it does not override Integration.reset().

Would it make sense to reset the Firebase client in this method? I was thinking either by calling FirebaseAnalytics.resetAnalyticsData() or simply setting the user ID to null with FirebaseAnalytics.setUserId(null). This way, the user can be cleared when they log out by calling Segment's Analytics.with(context).reset()

@Override
public void reset() {
  super.reset();

  firebaseAnalytics.resetAnalyticsData();
  OR
  firebaseAnalytics.setUserId(null);

  logger.verbose("firebaseAnalytics.reset();");
}

See:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions