Update EmailVerificationCheck middleware, allow users to edit email after registration in case of typos

This commit is contained in:
Daniel Supernault 2019-09-01 17:54:06 -06:00
parent fe2627c60a
commit 29e23d80cb
No known key found for this signature in database
GPG Key ID: 0DEF1C662C9033F7
1 changed files with 7 additions and 1 deletions

View File

@ -19,7 +19,13 @@ class EmailVerificationCheck
if ($request->user() && if ($request->user() &&
config('pixelfed.enforce_email_verification') && config('pixelfed.enforce_email_verification') &&
is_null($request->user()->email_verified_at) && is_null($request->user()->email_verified_at) &&
!$request->is('i/verify-email', 'log*', 'i/confirm-email/*', 'settings/home') !$request->is(
'i/verify-email',
'log*',
'i/confirm-email/*',
'settings/home',
'settings/email'
)
) { ) {
return redirect('/i/verify-email'); return redirect('/i/verify-email');
} }