src/Ease/User.php
public function tryToLogin($formData)
    {
        if (!count($formData)) {
            return;
        }
        $login    = $this->dblink->addSlashes($formData[$this->loginColumn]);
        $password = $this->dblink->AddSlashes($formData[$this->passwordColumn]);
        if (!$login) {
            $this->addStatusMessage(_('missing login'), 'error');

            return;
        }
        if (!$password) {
            $this->addStatusMessage(_('missing password'), 'error');

            return;
        }
        $this->setObjectIdentity(['keyColumn' => $this->loginColumn]);
        if ($this->loadFromSQL($login)) {
            $this->setObjectName();
            $this->resetObjectIdentity(['ObjectName']);
            if ($this->passwordValidation($password,
                    $this->getDataValue($this->passwordColumn))) {
                if ($this->isAccountEnabled()) {
                    return $this->loginSuccess();
                } else {
                    $this->userID = null;

                    return false;
                }
            } else {
                $this->userID = null;
                if (count($this->getData())) {
                    $this->addStatusMessage(_('invalid password'), 'error');
                }
                $this->dataReset();

                return false;
            }
        } else {
            $this->addStatusMessage(sprintf(_('user %s does not exist'), $login,
                    'error'));

            return false;
        }
    }
public function tryToLogin($formData)
    {
        if (!count($formData)) {
            return;
        }
        $login    = $this->dblink->addSlashes($formData[$this->loginColumn]);
        $password = $this->dblink->AddSlashes($formData[$this->passwordColumn]);
        if (!$login) {
            $this->addStatusMessage(_('missing login'), 'error');

            return;
        }
        if (!$password) {
            $this->addStatusMessage(_('missing password'), 'error');

            return;
        }
        $this->setObjectIdentity(['keyColumn' => $this->loginColumn]);
        if ($this->loadFromSQL($login)) {
            $this->setObjectName();
            $this->resetObjectIdentity(['ObjectName']);
            if ($this->passwordValidation($password,
                    $this->getDataValue($this->passwordColumn))) {
                if ($this->isAccountEnabled()) {
                    return $this->loginSuccess();
                } else {
                    $this->userID = null;

                    return false;
                }
            } else {
                $this->userID = null;
                if (count($this->getData())) {
                    $this->addStatusMessage(_('invalid password'), 'error');
                }
                $this->dataReset();

                return false;
            }
        } else {
            $this->addStatusMessage(sprintf(_('user %s does not exist'), $login,
                    'error'));

            return false;
        }
    }
Pokusí se o přihlášení.
Try to Sign in.

@param array $formData pole dat z přihlaš. formuláře např. $_REQUEST

@return null|boolean