From 18a01b684ae57655fb321d3ef2192bc90e45988e Mon Sep 17 00:00:00 2001 From: Anonomit Date: Sun, 13 Nov 2022 23:58:10 -0500 Subject: [PATCH] Fixes --- Server.lua | 2 ++ Windows/ServerWindow.xml | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Server.lua b/Server.lua index d1c8cb9..4017ffc 100644 --- a/Server.lua +++ b/Server.lua @@ -1119,6 +1119,8 @@ function LootReserve.Server:PrepareLootTracking() -- Announce reserves when a group loot roll starts LootReserve:RegisterEvent("START_LOOT_ROLL", function(rollID) + if not self.CurrentSession then return end + local link = GetLootRollItemLink(rollID); if not link then return end diff --git a/Windows/ServerWindow.xml b/Windows/ServerWindow.xml index 3836d71..bee6d9b 100644 --- a/Windows/ServerWindow.xml +++ b/Windows/ServerWindow.xml @@ -446,6 +446,7 @@ players[i] = LootReserve:ColoredPlayer(players[i]); end end + local item = self:GetParent().Item; local disenchanter = LootReserve.Server:GetDisenchanter(); local menu = { @@ -475,7 +476,7 @@ table.insert(menu, 3, { text = format(disenchanter and "Send to Disenchanter: %s" or "Send to Disenchanter", disenchanter and LootReserve:ColoredPlayer(disenchanter)), disabled = not disenchanter, - func = function() LootReserve.Server:FinishRollRequest(self:GetParent().Item, nil, true); LootReserve.Server:RecordDisenchant(self:GetParent().Item, disenchanter); end, + func = function() LootReserve.Server:FinishRollRequest(self:GetParent().Item, nil, true); LootReserve.Server:RecordDisenchant(item, disenchanter); end, }); end if LootReserve:IsLootingItem(self:GetParent().Item) then