Skip to content

Commit

Permalink
fix: make test dc check work (2)
Browse files Browse the repository at this point in the history
  • Loading branch information
kalilistic committed Jun 11, 2024
1 parent 8a81103 commit 159cb1f
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion Dalamud.DrunkenToad/Core/Services/Ex/DataManagerEx.cs
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,15 @@ public uint GetWorldIdByName(string worldName)
/// <returns>indicator whether world is a test data center.</returns>
public bool IsTestDC(uint worldId)
{
var region = this.dataManager.GetExcelSheet<WorldDCGroupType>()?.GetRow(this.Worlds[worldId].DataCenterId)?.Region ?? 0;
var worlds = this.dataManager.GetExcelSheet<World>();
var dcs = this.dataManager.GetExcelSheet<WorldDCGroupType>();
var world = worlds?.GetRow(worldId);
if (world == null)
{
return false;
}

var region = dcs?.GetRow(world.DataCenter.Row)?.Region ?? 0;
return region == 7;
}

Expand Down

0 comments on commit 159cb1f

Please sign in to comment.