Error setting tag environment in 40000.4-Release
jabernat opened this issue ยท 1 comments
I'm getting this error when oUF_Reputation tries to register its tags:
1x oUF-1.5.2\elements\tags.lua:316: 'setfenv' cannot change environment of given object
oUF-1.5.2\elements\tags.lua:316: in function <oUF\elements\tags.lua:310>
oUF_Reputation-40000.4-Release\oUF_Reputation.lua:61: in function `enable'
oUF-1.5.2\ouf.lua:260: in function `EnableElement'
oUF-1.5.2\ouf.lua:439: in function <oUF\ouf.lua:391>
(tail call): ?:
oUF-1.5.2\ouf.lua:702: in function `Spawn'
_Underscore.Units-4.0.0.1\_Underscore.Units.oUF.lua:775: in main chunk
I tracked it to when the "reputation" tag is getting set. It seems like setfenv fails when called on GetWatchedFactionInfo by oUF. Wrapping GetWatchedFactionInfo with a function in oUF_Rep's tags table cleared the error up.
Fixed in f4b1115