Skip to content

Commit

Permalink
2.6.4
Browse files Browse the repository at this point in the history
Fixed error when entering follower dungeons with session data displayed
  • Loading branch information
Noshei committed Oct 23, 2024
1 parent 5587e66 commit f41d545
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 5 deletions.
9 changes: 6 additions & 3 deletions GatheringTracker.lua
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,9 @@ function GT:AllignColumns()
end
for i, id in ipairs(GT.Display.Order) do
for index, string in ipairs(GT.Display.Frames[id].text) do
if not GT.Display.ColumnSize[index] then
GT:CheckColumnSize(index, GT.Display.Frames[id].text[index])
end
string:SetWidth(GT.Display.ColumnSize[index])
end
end
Expand Down Expand Up @@ -626,7 +629,7 @@ function GT:GetItemRowData(itemID)
if GT.db.profile.General.sessionOnly then
GT.Debug("GetItemRowData", 3, "Session Counts", itemID)
return GT.InventoryData[itemID].sessionCounts
elseif GT.db.profile.General.sessionItems and not IsInGroup() then
elseif GT.db.profile.General.sessionItems and not GT:IsInGroup() then
local data = {}
for playerIndex, count in ipairs(GT.InventoryData[itemID].counts) do
table.insert(data, count)
Expand Down Expand Up @@ -695,7 +698,7 @@ function GT:SetupTotalsRow()
GT.db.profile.General.sessionOnly
)
table.insert(playerTotals, playerTotal)
if GT.db.profile.General.sessionItems and not GT.db.profile.General.sessionOnly and not IsInGroup() then
if GT.db.profile.General.sessionItems and not GT.db.profile.General.sessionOnly and not GT:IsInGroup() then
local playerTotalSession, playerPriceSession = GT:CalculatePlayerTotals(
senderIndex,
true,
Expand Down Expand Up @@ -863,7 +866,7 @@ function GT:InventoryUpdate(event, wait)

GT:ProcessSoloData(event)

if GT.db.profile.General.groupType > 0 and IsInGroup() then
if GT.db.profile.General.groupType > 0 and GT:IsInGroup() then
GT:CreateDataMessage(event)
end
end
Expand Down
5 changes: 3 additions & 2 deletions GatheringTracker.toc
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
## Interface: 110002
## Interface: 110005
## Title: Gathering Tracker
## Notes: Addon for tracking gathered items, supports solo players and groups
## Author: Noshei
## Version: 2.6.3
## Version: 2.6.4
## OptionalDeps: TradeSkillMaster, RECrystallize, Auctionator
## SavedVariables: GatheringTrackerDB
## AddonCompartmentFunc: GatheringTracker_OnAddonCompartmentClick
Expand All @@ -15,6 +15,7 @@ DisplayCollapse.lua
Utilities.lua
FilterButton.lua
NotificationHandler.lua
Alerts.lua
Constants.lua
Config.lua
Broker.lua
Expand Down
8 changes: 8 additions & 0 deletions Utilities.lua
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,14 @@ function GT:GroupDisplayCheck()
return true
end

function GT:IsInGroup()
-- Extention of IsInGroup to return false when in follower dungeons
if C_LFGInfo.IsInLFGFollowerDungeon() == true then
return false
end
return IsInGroup()
end

function GT:SetChatType()
local soloMode = GT.db.profile.General.groupType == 0 or GT.db.profile.General.groupType == 2
local groupMode = GT.db.profile.General.groupType > 0
Expand Down

0 comments on commit f41d545

Please sign in to comment.