summaryrefslogtreecommitdiff
path: root/indra/newview/llgiveinventory.cpp
diff options
context:
space:
mode:
authorandreykproductengine <akleshchev@productengine.com>2017-02-15 20:40:03 +0200
committerandreykproductengine <akleshchev@productengine.com>2017-02-15 20:40:03 +0200
commit605160d501158362ced3e62425bdcd8d28895fd5 (patch)
tree0bd0338860645e47902b9f761d6309bc46688116 /indra/newview/llgiveinventory.cpp
parent9c015df3fab0b5cc229ad1a0393e5da50ee29883 (diff)
MAINT-7118 Swapping legacy people API with new cache
Diffstat (limited to 'indra/newview/llgiveinventory.cpp')
-rw-r--r--indra/newview/llgiveinventory.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/newview/llgiveinventory.cpp b/indra/newview/llgiveinventory.cpp
index b2271cf4ff..3ab8fed2c6 100644
--- a/indra/newview/llgiveinventory.cpp
+++ b/indra/newview/llgiveinventory.cpp
@@ -36,6 +36,7 @@
#include "llagentdata.h"
#include "llagentui.h"
#include "llagentwearables.h"
+#include "llavatarnamecache.h"
#include "llfloatertools.h" // for gFloaterTool
#include "llhudeffecttrail.h"
#include "llhudmanager.h"
@@ -327,12 +328,12 @@ void LLGiveInventory::logInventoryOffer(const LLUUID& to_agent, const LLUUID &im
// If this item was given by drag-and-drop on avatar while IM panel wasn't open, log this action to IM history.
else
{
- std::string full_name;
- if (gCacheName->getFullName(to_agent, full_name))
+ LLAvatarName av_name;
+ if (LLAvatarNameCache::get(to_agent, &av_name))
{
// Build a new format username or firstname_lastname for legacy names
// to use it for a history log filename.
- full_name = LLCacheName::buildUsername(full_name);
+ std::string full_name = LLCacheName::buildUsername(av_name.getUserName());
LLUIString message = LLTrans::getString(message_name + "-im");
message.setArgs(args);
LLIMModel::instance().logToFile(full_name, LLTrans::getString("SECOND_LIFE"), im_session_id, message.getString());