Skip to content

Commit

Permalink
Merge pull request #27070 from AliN11/patch-1
Browse files Browse the repository at this point in the history
[5.7] Stop email re-verification with same link
  • Loading branch information
taylorotwell authored Jan 5, 2019
2 parents 33503c0 + be70858 commit 04a96d7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Illuminate/Foundation/Auth/VerifiesEmails.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ public function verify(Request $request)
throw new AuthorizationException;
}

if ($request->user()->hasVerifiedEmail()) {
return redirect($this->redirectPath());
}

if ($request->user()->markEmailAsVerified()) {
event(new Verified($request->user()));
}
Expand Down

0 comments on commit 04a96d7

Please sign in to comment.