Skip to content

Commit

Permalink
Revert the old code
Browse files Browse the repository at this point in the history
  • Loading branch information
a7ul committed Nov 25, 2017
1 parent 7423a1f commit 15b2240
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,16 @@ public String getName() {

@ReactMethod
public void setHandlerforNativeException(Callback customHandler, final boolean forceToQuit){
this.callbackHolder = customHandler;
callbackHolder = customHandler;

Thread.setDefaultUncaughtExceptionHandler(new Thread.UncaughtExceptionHandler() {
@Override
public void uncaughtException(Thread thread, Throwable throwable) {
activity = getCurrentActivity();
String stackTraceString = Log.getStackTraceString(throwable);
callbackHolder.invoke(stackTraceString);

if (BuildConfig.DEBUG) {
Log.d("ERROR",stackTraceString);
}
Log.d("ERROR",stackTraceString);


Intent i = new Intent();
i.setClass(activity, errorIntentTargetClass);
Expand Down

0 comments on commit 15b2240

Please sign in to comment.