mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
fix(core): if your username is empty, use toxPK instead in groups
This commit is contained in:
parent
066bdc5cc1
commit
72bcc6acaf
|
@ -377,7 +377,8 @@ ChatMessage::Ptr GenericChatForm::createMessage(const ToxPk& author, const QStri
|
||||||
{
|
{
|
||||||
const Core* core = Core::getInstance();
|
const Core* core = Core::getInstance();
|
||||||
bool isSelf = author == core->getSelfId().getPublicKey();
|
bool isSelf = author == core->getSelfId().getPublicKey();
|
||||||
QString authorStr = isSelf ? core->getUsername() : resolveToxPk(author);
|
QString myNickName = core->getUsername().isEmpty() ? author.toString() : core->getUsername();
|
||||||
|
QString authorStr = isSelf ? myNickName : resolveToxPk(author);
|
||||||
if (getLatestDate() != QDate::currentDate()) {
|
if (getLatestDate() != QDate::currentDate()) {
|
||||||
addSystemDateMessage();
|
addSystemDateMessage();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user