core: move expansion checks into module header
This commit is contained in:
@@ -1,17 +1,14 @@
|
||||
local _G = _G or getfenv(0)
|
||||
local libdebuff = ShaguTweaks.libdebuff
|
||||
local GetExpansion = ShaguTweaks.GetExpansion
|
||||
|
||||
-- there are already debuff timers in tbc+
|
||||
if GetExpansion() ~= "vanilla" then return end
|
||||
|
||||
local module = ShaguTweaks:register({
|
||||
title = "Debuff Timer",
|
||||
description = "Show debuff durations on the target unit frame.",
|
||||
expansions = { ["vanilla"] = true, ["tbc"] = nil },
|
||||
enabled = true,
|
||||
})
|
||||
|
||||
local UnitDebuff = ShaguTweaks.libdebuff.UnitDebuff
|
||||
local libdebuff = ShaguTweaks.libdebuff
|
||||
local UnitDebuff = libdebuff and libdebuff.UnitDebuff
|
||||
|
||||
local function TimeConvert(remaining)
|
||||
local color = "|cffffffff"
|
||||
|
||||
Reference in New Issue
Block a user