c6843f3 - Refactor updateIndicators to get auras when they're applied
[wowui.git] / OmaRF / UpdateNameHook.lua
1 local UnitName = UnitName;
2
3 hooksecurefunc("CompactUnitFrame_UpdateName", function(frame)
4     -- allowClassColorsForNPCs only in regular raid frames,
5     -- match only to them
6     if frame.optionTable.allowClassColorsForNPCs ~= nil then
7         local name, _;
8         name, _ = UnitName(frame.unit);
9         if name then
10             frame.name:SetFont(STANDARD_TEXT_FONT, 12, "");
11             frame.name:SetText(name);
12         end
13     end
14 end);