using System.Collections.Generic; using API.Entities; namespace API.Extensions { public static class SeriesExtensions { /// /// Checks against all the name variables of the Series if it matches anything in the list. /// /// /// /// public static bool NameInList(this Series series, IEnumerable list) { foreach (var name in list) { if (name == series.Name || name == series.LocalizedName || name == series.OriginalName || name == series.NormalizedName) { return true; } } return false; } } }