private void MergeWhitelistWithReservedSlots()
{
List<String> vip = new List<String>(fSettingWhitelist);
foreach (String reserved in fReservedSlots) {
bool dupe = false;
// Check for duplicates
foreach (String item in fSettingWhitelist) {
List<String> tokens = new List<String>(Regex.Split(item, @"\s+"));
if (tokens[0] == reserved) {
if (DebugLevel >= 6) ConsoleDebug("Reserved slots list duplicates Whitelist name ^b" + reserved);
dupe = true;
break;
}
}
if (dupe) continue;
// Otherwise, add it
vip.Add(reserved);
}
fSettingWhitelist.Clear();
// clean up the list
foreach (String v in vip) {
if (String.IsNullOrEmpty(v)) continue;
if (v == INVALID_NAME_TAG_GUID) continue;
if (v.Contains("[")) continue;
fSettingWhitelist.Add(v);
}
}