Fix a crash if nearby_chat is not created (default on FUI)

meow-7.2.2
Nicky 2012-01-20 00:00:29 +01:00
parent 47672f6cd5
commit 1c8e2cff0f
1 changed files with 2 additions and 1 deletions

View File

@ -822,7 +822,8 @@ void LLNearbyChatHandler::onAvatarNameLookup(const LLUUID& agent_id, const LLAva
LLViewerChat::getChatColor(chat_msg, chatcolor);
gConsole->addConsoleLine(consoleChat, chatcolor);
LLNearbyChat* nearby_chat = LLFloaterReg::getTypedInstance<LLNearbyChat>("nearby_chat", LLSD());
gConsole->setVisible(!nearby_chat->getVisible());
if( nearby_chat )
gConsole->setVisible(!nearby_chat->getVisible());
}
void LLNearbyChatHandler::onDeleteToast(LLToast* toast)