for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace App\Modules\Admins\Http\Requests\Auth;
use Illuminate\Auth\Events\Verified;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Validation\Validator;
/**
* @see \Illuminate\Foundation\Auth\EmailVerificationRequest
*/
class EmailVerificationRequest extends FormRequest
{
* Determine if the user is authorized to make this request.
*
* @return bool
public function authorize()
if (!hash_equals((string) $this->user('admin')->getKey(), (string) $this->route('id'))) {
return false;
}
if (!hash_equals(sha1($this->user('admin')->getEmailForVerification()), (string) $this->route('hash'))) {
return true;
* Get the validation rules that apply to the request.
* @return array
public function rules()
return [
//
];
* Fulfill the email verification request.
* @return void
public function fulfill()
if (!$this->user('admin')->hasVerifiedEmail()) {
$this->user('admin')->markEmailAsVerified();
event(new Verified($this->user('admin')));
* Configure the validator instance.
public function withValidator(Validator $validator)
return $validator;
return $validator
Illuminate\Validation\Validator
void