Fix bug 49898

This commit is contained in:
Kulikova Svetlana
2021-04-23 17:14:55 +03:00
parent 3b2691b186
commit 758cd5d599

View File

@ -109,12 +109,15 @@ struct STitleInfo
// Разделитель ;
std::wstring getAuthors()
{
return std::accumulate(m_arAuthors.begin(), m_arAuthors.end(), std::wstring(),
std::wstring sRes = std::accumulate(m_arAuthors.begin(), m_arAuthors.end(), std::wstring(),
[] (std::wstring& sRes, const SAuthor& vElem) { return sRes +=
(vElem.middle_name.empty() ? L"" : (vElem.middle_name + L' ')) +
(vElem.first_name.empty() ? L"" : (vElem.first_name + L' ')) +
(vElem.last_name.empty() ? L"" : (vElem.last_name + L' ')) +
vElem.nickname + L';'; });
(vElem.middle_name.empty() ? L"" : (vElem.middle_name + L' ')) +
(vElem.first_name.empty() ? L"" : (vElem.first_name + L' ')) +
(vElem.last_name.empty() ? L"" : (vElem.last_name + L' ')) +
vElem.nickname + L';'; });
if (!sRes.empty())
sRes.erase(sRes.end() - 1);
return sRes;
}
};