Originally Posted by Phanx
This is incorrect for two reasons
|
No, this way is correct to expose your addon to other addons
local t, n = ...;
MY_ADDON = n;
|
or
Code:
local t, n = ...;
_G[t] = n;
or my way
Code:
local title, M = ...;
local frame = CreateFrame("Frame", title);
M[0] = frame[0];
setmetatable(M, { __index = getmetatable(frame).__index });
setmetatable(frame, { __index = M, __newindex = M });