From 231d8b48c13e21470630faea23d6ca1ce87f25a4 Mon Sep 17 00:00:00 2001 From: Casey Raethke Date: Thu, 22 Aug 2024 11:49:51 -0500 Subject: [PATCH] Fix weapon validator's usage of statModContext --- libs/StatLogic/StatLogic.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libs/StatLogic/StatLogic.lua b/libs/StatLogic/StatLogic.lua index 9dd1dad..ea6d7e4 100644 --- a/libs/StatLogic/StatLogic.lua +++ b/libs/StatLogic/StatLogic.lua @@ -1037,10 +1037,10 @@ addon.StatModValidators = { }, }, weapon = { - validate = function(case, _, overrideStats) + validate = function(case, _, statModContext) local subclassID - if overrideStats then - subclassID = overrideStats.subclassID + if statModContext then + subclassID = statModContext.overrideStats.subclassID else local weapon = GetInventoryItemID("player", INVSLOT_MAINHAND) if weapon then @@ -1328,7 +1328,7 @@ do local level = context.level local profileSpec = context.profile .. context.spec - if not level or level == UnitLevel("player") then + if (not level or level == UnitLevel("player")) and not next(context.overrideStats) then value = StatModCache[statMod][profileSpec] end