local IRF2 = InvenRaidFrames2

local _G = getfenv(0)
local UnitAura = _G.UnitAura
local enableBuff, enableDebuff, enableSelf
local auraHandler = {}
local index, name, rank, icon, count, debuffType, duration, expirationTime, isMine, isStealable

function IRF2:RegisterAuraEvent(name, func)
	auraHandler[name] = func
end

function IRF2:GetAuraEventFunction(name)
	return auraHandler[name]
end

function IRF2:AuraUpdate(unit)
	if IRF2.units[unit] and IRF2.units[unit].unit == unit and IRF2.units[unit]:IsShown() then
		for _, func in pairs(auraHandler) do
			func(IRF2.units[unit])
		end
	end
end