From 691994b7767fb2b4859f7e8c8ca67166259a034e Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sun, 28 Jun 2020 00:42:50 -0700 Subject: Update gradle and add bugsnag to sample app --- sample/src/main/AndroidManifest.xml | 3 +++ .../src/main/kotlin/ca/allanwang/kau/sample/SampleApp.kt | 16 +++++++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) (limited to 'sample/src/main') diff --git a/sample/src/main/AndroidManifest.xml b/sample/src/main/AndroidManifest.xml index 5846c6b..b205c51 100644 --- a/sample/src/main/AndroidManifest.xml +++ b/sample/src/main/AndroidManifest.xml @@ -57,6 +57,9 @@ android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/kau_file_paths" /> + \ No newline at end of file diff --git a/sample/src/main/kotlin/ca/allanwang/kau/sample/SampleApp.kt b/sample/src/main/kotlin/ca/allanwang/kau/sample/SampleApp.kt index 282f9ff..bead882 100644 --- a/sample/src/main/kotlin/ca/allanwang/kau/sample/SampleApp.kt +++ b/sample/src/main/kotlin/ca/allanwang/kau/sample/SampleApp.kt @@ -16,10 +16,24 @@ package ca.allanwang.kau.sample import android.app.Application +import com.bugsnag.android.Bugsnag +import com.bugsnag.android.Configuration import dagger.hilt.android.HiltAndroidApp /** * Created by Allan Wang on 2017-06-08. */ @HiltAndroidApp -class SampleApp : Application() +class SampleApp : Application() { + override fun onCreate() { + super.onCreate() +// initBugsnag() + } + + private fun initBugsnag() { + if (BuildConfig.DEBUG) { + return + } + Bugsnag.start(this) + } +} -- cgit v1.2.3