src/Handlers/BootstrapMFALoginHandler.php
public function doLogin($data, MemberLoginForm $form, HTTPRequest $request)
    {
        /**
         * @var ValidationResult $message
         * @var Member|MemberExtension $member
         */
        $member = $this->checkLogin($data, $request, $message);

        if (!$member) {
            return $this->redirectBack();
        }

        // If we're in grace period, continue to the parent
        if ($member->isInGracePeriod()) {
            return parent::doLogin($data, $form, $request);
        }

        if ($message->isValid()) {
            /** @var Session $session */
            $session = $request->getSession();
            $session->set(BootstrapMFAAuthenticator::SESSION_KEY . '.MemberID', $member->ID);
            $session->set(BootstrapMFAAuthenticator::SESSION_KEY . '.Data', $data);
            if (!empty($data['BackURL'])) {
                $session->set(BootstrapMFAAuthenticator::SESSION_KEY . '.BackURL', $data['BackURL']);
            }

            return $this->redirect($this->link('verify'));
        }

        return $this->redirectBack();
    }
public function doLogin($data, MemberLoginForm $form, HTTPRequest $request)
    {
        /**
         * @var ValidationResult $message
         * @var Member|MemberExtension $member
         */
        $member = $this->checkLogin($data, $request, $message);

        if (!$member) {
            return $this->redirectBack();
        }

        // If we're in grace period, continue to the parent
        if ($member->isInGracePeriod()) {
            return parent::doLogin($data, $form, $request);
        }

        if ($message->isValid()) {
            /** @var Session $session */
            $session = $request->getSession();
            $session->set(BootstrapMFAAuthenticator::SESSION_KEY . '.MemberID', $member->ID);
            $session->set(BootstrapMFAAuthenticator::SESSION_KEY . '.Data', $data);
            if (!empty($data['BackURL'])) {
                $session->set(BootstrapMFAAuthenticator::SESSION_KEY . '.BackURL', $data['BackURL']);
            }

            return $this->redirect($this->link('verify'));
        }

        return $this->redirectBack();
    }
public function doLogin ( $ data , MemberLoginForm $ form , HTTPRequest $ request ) { /**
         * @var ValidationResult $message
         * @var Member|MemberExtension $member
         */ $ member = $ this -> checkLogin ( $ data , $ request , $ message ) ; if ( ! $ member ) { return $ this -> redirectBack ( ) ; } // If we're in grace period, continue to the parent if ( $ member -> isInGracePeriod ( ) ) { return parent :: doLogin ( $ data , $ form , $ request ) ; } if ( $ message -> isValid ( ) ) { /** @var Session $session */ $ session = $ request -> getSession ( ) ; $ session -> set ( BootstrapMFAAuthenticator :: SESSION_KEY . '.MemberID' , $ member -> ID ) ; $ session -> set ( BootstrapMFAAuthenticator :: SESSION_KEY . '.Data' , $ data ) ; if ( ! empty ( $ data [ 'BackURL' ] ) ) { $ session -> set ( BootstrapMFAAuthenticator :: SESSION_KEY . '.BackURL' , $ data [ 'BackURL' ] ) ; } return $ this -> redirect ( $ this -> link ( 'verify' ) ) ; } return $ this -> redirectBack ( ) ; }
Override the doLogin method to do our own work here

@param array $data
@param MemberLoginForm $form
@param HTTPRequest $request
@return HTTPResponse
Override the doLogin method to do our own work here