From 083471eb212e87fac834638fbc49787bba0c4678 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sat, 6 Mar 2021 13:55:18 +0300 Subject: less shit with this "(Unknown contact)" --- plugins/IEView/src/HTMLBuilder.cpp | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'plugins/IEView/src') diff --git a/plugins/IEView/src/HTMLBuilder.cpp b/plugins/IEView/src/HTMLBuilder.cpp index bb9aeae778..a0ad5d7528 100644 --- a/plugins/IEView/src/HTMLBuilder.cpp +++ b/plugins/IEView/src/HTMLBuilder.cpp @@ -167,17 +167,12 @@ wchar_t* HTMLBuilder::getContactName(MCONTACT hContact, const char *szProto) if (str != nullptr) return str; - str = Clist_GetContactDisplayName(hContact); - if (str != nullptr) - return mir_wstrdup(str); - - return mir_wstrdup(TranslateT("(Unknown contact)")); + return mir_wstrdup(Clist_GetContactDisplayName(hContact)); } char* HTMLBuilder::getEncodedContactName(MCONTACT hContact, const char *szProto) { - ptrW name(getContactName(hContact, szProto)); - return encodeUTF8(hContact, (name != NULL) ? name : TranslateT("(Unknown contact)"), ENF_NAMESMILEYS, true); + return encodeUTF8(hContact, ptrW(getContactName(hContact, szProto)), ENF_NAMESMILEYS, true); } void HTMLBuilder::appendEventNew(IEView *view, IEVIEWEVENT *event) -- cgit v1.2.3