Skip to content
This repository has been archived by the owner on Sep 17, 2023. It is now read-only.

Commit

Permalink
Attempt to fix super.NotFound ANR reports...
Browse files Browse the repository at this point in the history
  • Loading branch information
maxieds committed May 12, 2018
1 parent 652f3ff commit 0ef1aea
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ android {
applicationId "com.maxieds.chameleonminilivedebugger"
minSdkVersion 21
targetSdkVersion 27
versionCode 41
versionName "0.4.1"
versionCode 42
versionName "0.4.2"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ public void uncaughtException(Thread thread, Throwable ex) {
String msgParam = "An unknown error happened in the app. Please upgrade to the latest version if a newer one is available, or ";
msgParam += "contact the developer at [email protected] to report whatever action you took to generate this error!";
appendNewLog(LogEntryMetadataRecord.createDefaultEventRecord("UNRECOGNIZED EXCEPTION", msgParam));
System.exit(-1);
}
};

Expand All @@ -201,11 +202,11 @@ public void uncaughtException(Thread thread, Throwable ex) {
protected void onCreate(Bundle savedInstanceState) {

// fix bug where the tabs are blank when the application is relaunched:
super.onCreate(savedInstanceState); // should fix most of the crashes in the ANR report on Play Store
if(!BuildConfig.DEBUG)
Fabric.with(this, new Crashlytics());
if(runningActivity == null || !isTaskRoot()) {
super.onCreate(savedInstanceState);
Thread.setDefaultUncaughtExceptionHandler(unCaughtExceptionHandler);
if(!BuildConfig.DEBUG)
Fabric.with(this, new Crashlytics());
}
if(!isTaskRoot()) {
Log.w(TAG, "ReLaunch Intent Action: " + getIntent().getAction());
Expand Down

0 comments on commit 0ef1aea

Please sign in to comment.