public static void AddDistinct <T>(this HashSet <T> hash, IEnumerable <T> items) { if (items != null) { items.ForEach(t => hash.AddDistinct(t)); } }