-2

I want to disable the crashlytics at run time in iOS app. I could see it is possible using the latest Firebase api. How to do this with old Fabric/Crashlytics api?

Update: My app will get locked if the user goes to background, if the app is locked then without user authentication I shouldn't call any api(http request, accessing database). So I want to restrict the crashlytics api as well. When the app comes to foreground, crashlytics/fabric calling the http request so I want to avoid this if the user is not authenticated.

Asad Ali Choudhry
  • 4,985
  • 4
  • 31
  • 36
RJV Kumar
  • 2,408
  • 1
  • 19
  • 28

1 Answers1

0

Fabric/Firebaser here - you can conditionally choose to initialize or skip the initialization of Fabric with an opt-in flag set by your user, but there isn't a (supported) way to totally disable Crashlytics from running when it has already been initialized. There is a way, however, to control your submission behavior with Crashlytics, but might not suit your use case. Also, check out these docs for more information on the opt-in/opt-out mentioned above.

Kevin Kokomani
  • 1,568
  • 7
  • 14
  • Thanks, but I referred the opt-in docs which might not be useful for my use-case where we can't advise the user to kill the app. Is there any other way to solve this? or Can Firebase api will work for this use case? – RJV Kumar Jul 16 '19 at 09:45
  • No, there isn't a way to do that in Firebase either. https://firebase.google.com/docs/crashlytics/customize-crash-reports#enable_opt_in_reporting for Firebase docs on opt-in reporting. You might also want to refer to this answer for more info: https://stackoverflow.com/questions/52063465/disable-firebase-crashlytics-for-android/52064284 – Kevin Kokomani Jul 17 '19 at 19:57