From ccc51ea76ca5cb674f95c95020009549abfaac37 Mon Sep 17 00:00:00 2001 From: Scott Pabin Date: Sat, 11 Mar 2023 22:25:15 -0700 Subject: [PATCH 1/2] Add code example for implementing MustVerifyEmail Many people try to "implement" with 'use MustVerifyEmail;'. Adding the code example will help reduce the misunderstanding. --- 3.x/features/registration.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/3.x/features/registration.md b/3.x/features/registration.md index 178bda9..6d57ff8 100644 --- a/3.x/features/registration.md +++ b/3.x/features/registration.md @@ -121,6 +121,12 @@ use Laravel\Fortify\Features; Next, you should ensure that your `App\Models\User` class implements the `Illuminate\Contracts\Auth\MustVerifyEmail` interface. This interface is already imported into this model for you. +```php +use Illuminate\Contracts\Auth\MustVerifyEmail; + +class User extends Authenticatable implements MustVerifyEmail +``` + Once these two setup steps have been completed, newly registered users will receive an email prompting them to verify their email address ownership. :::tip Laravel Mail From bfe118ce523154abbb5ef6edc5af055037c6718e Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Sun, 12 Mar 2023 09:34:50 -0500 Subject: [PATCH 2/2] Update registration.md --- 3.x/features/registration.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/3.x/features/registration.md b/3.x/features/registration.md index 6d57ff8..61cdd14 100644 --- a/3.x/features/registration.md +++ b/3.x/features/registration.md @@ -119,12 +119,15 @@ use Laravel\Fortify\Features; ], ``` -Next, you should ensure that your `App\Models\User` class implements the `Illuminate\Contracts\Auth\MustVerifyEmail` interface. This interface is already imported into this model for you. +Next, you should ensure that your `App\Models\User` class implements the `Illuminate\Contracts\Auth\MustVerifyEmail` interface. This interface is already imported into this model for you: ```php use Illuminate\Contracts\Auth\MustVerifyEmail; class User extends Authenticatable implements MustVerifyEmail +{ + // ... +} ``` Once these two setup steps have been completed, newly registered users will receive an email prompting them to verify their email address ownership.