blessing-skin-server/app/Http/Middleware/CheckUserVerified.php
2019-04-19 19:36:36 +08:00

14 lines
280 B
PHP

<?php
namespace App\Http\Middleware;
class CheckUserVerified
{
public function handle($request, \Closure $next)
{
abort_if(option('require_verification') && ! auth()->user()->verified, 403, trans('auth.check.verified'));
return $next($request);
}
}