문제

I've just added my app on Crashlytics. I put the API key in the AndroidManifest.xml file and I call Crashlytics.start(this) inside of the onCreate() method of my launcher Activity.

I've got +20 Activities and 20 Fragments.

Do I need to put Crashlytics.start(this) in every Activity's onCreate() method in order to make Crashlytics able to track whole my app?

도움이 되었습니까?

해결책

Taken from the Crashalytics SDK FAQ:

If you have an Application subclass, then you can place Crashlytics.start() in the onCreate() method there! Otherwise, if you have multiple launch activities in your app, then add Crashlytics.start(this) to each launch activity. Crashlytics is only initialized the first time you call start, so calling it multiple times won't cause any issues!

http://support.crashlytics.com/knowledgebase/articles/206230-can-i-move-crashlytics-start-this-

With this in mind, I think that having started Crashalytics on your onCreate method of you launch activity will suffice. Bugsense does more or less the same things and It´s started on the launch Activity only.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top