Fork from https://github.com/rayzl0523minibear/UncaughtExceptionHandler