This has been fixed.
Patch 5.0.4 introduced an annoying bug to deal with.
Blizzard accidentally declared "_" to be global, so if your addon uses "_" as a global it will cause the GlyphUI frame to not work.
It's an easy fix, instead of:
local class _, class = UnitClass("player")
Just declare _ as a local variable:
local _, class _, class = UnitClass("player")
or you can achieve it another way using the select method:
local class = select(2, UnitClass("player"))
Using local variable over global variables is good addon practice for a variety of reasons, some of which include speed of access, interactions with other addons/Blizzard UI, and just not polluting the global namespace.
Good news however is that this is already fixed on the beta and should be slated for patch 5.0.5.
Mikk wrote a nice little utility which helps find global leakage in your addons. You can get it from WowAce here.
- 7 comments
- 7 comments
Facts
- Date created
- Sep 04, 2012
- Last updated
- Oct 23, 2012
- Reply
- #8
Nilvalue Nov 12, 2012 at 10:47 UTC - 0 likesIt seems the problem has been fixed by blz in 5.05. But I still have the problem when I change talent: Ace3 or Bartender4 has been blocked by blz...
- Reply
- #7
420psilo Oct 28, 2012 at 18:25 UTC - 0 likesthis prob is getting rediculously frustrating. I honestly think that the addon being blamed is not even the one causing the issue, but rather a random finger pointing. I have to disable sooo many addons before it works....http://us.battle.net/wow/en/forum/topic/7004690454... this post by ELV from ELV ui seems to break it down very clearly. Ive made a post on the Bug forums. maybe if enuff noise is made it will be cleaned up.
- Reply
- #5
laric Sep 14, 2012 at 08:07 UTC - 0 likesDoesn't look like 5.0.5 solved this issue. I hope they include it in the 5.1 patch.
- Reply
- #4
420psilo Sep 09, 2012 at 03:12 UTC - 0 likesthank you guys . :) your hard work is always appreciated :) :) :)
- Reply
- #3
yossa Sep 04, 2012 at 16:46 UTC - 0 likesif you don't want to change lots of code you can also declare: local _
at the beginning of every lua file, which cause problems. I fixed like this all broken addons I use.
- Reply
- #2
Silmano Sep 04, 2012 at 08:29 UTC - 0 likesJust got an error reported for this, I was all worried on why would the addon call CastGlyph() function and then fail if it doesn't have anything to do with glyphs at all...
- Reply
- #1
Seerah Sep 04, 2012 at 04:23 UTC - 2 likesFor future reference, _ is a VALID VARIABLE NAME. So treat it like one, and localize it. It's just a convention that authors have made it a throw away variable.