Search code examples
androidfirebase-console

Firebase Crash Reporting, disable reports for debug builds


We are doing the beta-test of our android app this time. Is there any way to stop android emulators from sending crash reports to the Firebase Console? First we have to look at the devices of each problem to manually close them because we don't see if the problem comes from developing/testing or from a beta-tester.


Solution

  • Use this in your custom Application class onCreate method:

    FirebaseCrash.setCrashCollectionEnabled(!BuildConfig.DEBUG);
    

    If you compile the debug APK for emulators you are fine