Use helper function report

This commit is contained in:
Pig Fang 2018-07-22 11:36:00 +08:00
parent 5a9c9a6d3a
commit e2703aad84

View File

@ -160,8 +160,7 @@ class AuthController extends Controller
try {
Mail::to($request->input('email'))->send(new ForgotPassword($url));
} catch (\Exception $e) {
// Write the exception to log
app(\Illuminate\Foundation\Exceptions\Handler::class)->report($e);
report($e);
return json(trans('auth.mail.failed', ['msg' => $e->getMessage()]), 2);
}