Added a constructor with UncaughtExceptionHandler argument