2018-11-02 18:12:07 -04:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Http\Controllers\Auth;
|
|
|
|
|
|
|
|
use App\Http\Controllers\Controller;
|
2020-02-25 16:02:36 -05:00
|
|
|
use App\Providers\RouteServiceProvider;
|
2018-11-02 18:12:07 -04:00
|
|
|
use Illuminate\Foundation\Auth\VerifiesEmails;
|
2024-03-19 17:11:58 -04:00
|
|
|
use Illuminate\Routing\Controllers\HasMiddleware;
|
|
|
|
use Illuminate\Routing\Controllers\Middleware;
|
2018-11-02 18:12:07 -04:00
|
|
|
|
2024-03-19 17:11:58 -04:00
|
|
|
class VerificationController extends Controller implements HasMiddleware
|
2018-11-02 18:12:07 -04:00
|
|
|
{
|
|
|
|
/*
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
| Email Verification Controller
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
| This controller is responsible for handling email verification for any
|
|
|
|
| user that recently registered with the application. Emails may also
|
|
|
|
| be re-sent if the user didn't receive the original email message.
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
use VerifiesEmails;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Where to redirect users after verification.
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
2020-02-25 16:02:36 -05:00
|
|
|
protected $redirectTo = RouteServiceProvider::HOME;
|
2018-11-02 18:12:07 -04:00
|
|
|
|
|
|
|
/**
|
2024-03-19 17:11:58 -04:00
|
|
|
* Get the middleware that should be assigned to the controller.
|
2018-11-02 18:12:07 -04:00
|
|
|
*/
|
2024-03-19 17:11:58 -04:00
|
|
|
public static function middleware(): array
|
2018-11-02 18:12:07 -04:00
|
|
|
{
|
2024-03-19 17:11:58 -04:00
|
|
|
return [
|
|
|
|
'auth',
|
|
|
|
new Middleware('signed', only: [ 'verify' ]),
|
|
|
|
new Middleware('throttle:6,1', only: [ 'verify', 'resend' ]),
|
|
|
|
];
|
2018-11-02 18:12:07 -04:00
|
|
|
}
|
|
|
|
}
|