src/Auth/VerifyEmails/VerifyEmailBroker.php
public function verify(CanVerifyEmailContract $user, $token)
    {
        // If the responses from the validate method is not a user instance, we will
        // assume that it is a redirect and simply return it from this method and
        // the user is properly redirected having an error message on the post.
        $user = $this->validateVerification($user, $token);

        if (! $user instanceof CanVerifyEmailContract) {
            return $user;
        }

        $this->tokens->delete($token);

        $user->setVerified(true);

        $user->save();

        return VerifyEmailBrokerContract::EMAIL_VERIFIED;
    }
public function verify(CanVerifyEmailContract $user, $token)
    {
        // If the responses from the validate method is not a user instance, we will
        // assume that it is a redirect and simply return it from this method and
        // the user is properly redirected having an error message on the post.
        $user = $this->validateVerification($user, $token);

        if (! $user instanceof CanVerifyEmailContract) {
            return $user;
        }

        $this->tokens->delete($token);

        $user->setVerified(true);

        $user->save();

        return VerifyEmailBrokerContract::EMAIL_VERIFIED;
    }
public function verify ( CanVerifyEmailContract $ user , $ token ) { // If the responses from the validate method is not a user instance, we will // assume that it is a redirect and simply return it from this method and // the user is properly redirected having an error message on the post. $ user = $ this -> validateVerification ( $ user , $ token ) ; if ( ! $ user instanceof CanVerifyEmailContract ) { return $ user ; } $ this -> tokens -> delete ( $ token ) ; $ user -> setVerified ( true ) ; $ user -> save ( ) ; return VerifyEmailBrokerContract :: EMAIL_VERIFIED ; }
Verify the email address for the given token.

@param  \LaravelVerifyEmails\Contracts\Auth\CanVerifyEmail  $user
@param  string  $token
@return mixed
Verify the email address for the given token .