using FishNet.Documenting; using System.Collections.Generic; namespace FishNet.Utility.Extension { [APIExclude] public static class ListFN { /// /// Adds a value to the list only if the value does not already exist. /// /// Collection being added to. /// Value to add. public static void AddUnique(this List lst, T value) { if (!lst.Contains(value)) lst.Add(value); } } }