public function getUserByResetKey($resetKey)
    {
        if ((null == $resetKey) || (0 == strlen(trim($resetKey)))) {
            return $this->loadUser(self::USER_NOLOGIN, null, null);
        }

        $select = $this->db->select();
        $select->from('gems__user_passwords', array())
                ->joinLeft('gems__user_logins', 'gup_id_user = gul_id_user', array("gul_user_class", 'gul_id_organization', 'gul_login'))
                ->where('gup_reset_key = ?', $resetKey);

        if ($row = $this->db->fetchRow($select, null, \Zend_Db::FETCH_NUM)) {
            // \MUtil_Echo::track($row);
            return $this->loadUser($row[0], $row[1], $row[2]);
        }

        return $this->loadUser(self::USER_NOLOGIN, null, null);
    }
public function getUserByResetKey($resetKey)
    {
        if ((null == $resetKey) || (0 == strlen(trim($resetKey)))) {
            return $this->loadUser(self::USER_NOLOGIN, null, null);
        }

        $select = $this->db->select();
        $select->from('gems__user_passwords', array())
                ->joinLeft('gems__user_logins', 'gup_id_user = gul_id_user', array("gul_user_class", 'gul_id_organization', 'gul_login'))
                ->where('gup_reset_key = ?', $resetKey);

        if ($row = $this->db->fetchRow($select, null, \Zend_Db::FETCH_NUM)) {
            // \MUtil_Echo::track($row);
            return $this->loadUser($row[0], $row[1], $row[2]);
        }

        return $this->loadUser(self::USER_NOLOGIN, null, null);
    }
public function getUserByResetKey ( $ resetKey ) { if ( ( null == $ resetKey ) || ( 0 == strlen ( trim ( $ resetKey ) ) ) ) { return $ this -> loadUser ( self :: USER_NOLOGIN , null , null ) ; } $ select = $ this -> db -> select ( ) ; $ select -> from ( 'gems__user_passwords' , array ( ) ) -> joinLeft ( 'gems__user_logins' , 'gup_id_user = gul_id_user' , array ( "gul_user_class" , 'gul_id_organization' , 'gul_login' ) ) -> where ( 'gup_reset_key = ?' , $ resetKey ) ; if ( $ row = $ this -> db -> fetchRow ( $ select , null , \ Zend_Db :: FETCH_NUM ) ) { // \MUtil_Echo::track($row); return $ this -> loadUser ( $ row [ 0 ] , $ row [ 1 ] , $ row [ 2 ] ) ; } return $ this -> loadUser ( self :: USER_NOLOGIN , null , null ) ; }
Get the user having the reset key specified

@param string $resetKey
@return \Gems_User_User But ! ->isActive when the user does not exist
Get the user having the reset key specified