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:
parent
77af896427
commit
d92537fd87
1 changed files with 4 additions and 7 deletions
|
|
@ -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>();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue