Ticket #440: use_uid_if_user_name_is_empty.patch

File use_uid_if_user_name_is_empty.patch, 800 bytes (added by fthomas, 17 years ago)
  • clientgui/ProjectProcessingPage.cpp

     
    399399                ai->email_addr = (const char*)pWAP->m_AccountInfoPage->GetAccountEmailAddress().mb_str();
    400400                ai->passwd = (const char*)pWAP->m_AccountInfoPage->GetAccountPassword().mb_str();
    401401                ai->user_name = (const char*)::wxGetUserName().mb_str();
     402                if (ai->user_name.empty()) {
     403                    ai->user_name = (const char*)::wxGetUserId().mb_str();
     404                }
    402405
    403406                if (pWAP->m_AccountInfoPage->m_pAccountCreateCtrl->GetValue()) {
    404407                    pDoc->rpc.create_account(*ai);