Moved the else from Midas' commit that reset the groups allowed in the event of an error, we can just ignore it instead of resetting. Move initialization of the list to the constructor.

This commit is contained in:
Zack 2011-12-27 09:40:45 -05:00
parent 77af896427
commit d92537fd87

View file

@ -618,6 +618,7 @@ namespace TShockAPI.DB
DisableBuild = true; DisableBuild = true;
WorldID = string.Empty; WorldID = string.Empty;
AllowedIDs = new List<int>(); AllowedIDs = new List<int>();
AllowedGroups = new List<string>();
} }
public bool InArea(Rectangle point) public bool InArea(Rectangle point)
@ -673,10 +674,6 @@ namespace TShockAPI.DB
groupArr[i] = groupArr[i].Trim(); groupArr[i] = groupArr[i].Trim();
AllowedGroups = groupArr; AllowedGroups = groupArr;
}
else
{
AllowedGroups = new List<string>();
} }
} }