fix AddRange to allow any type of Collection<>, not just List<>

This commit is contained in:
Michael Becker 2024-07-21 22:37:57 -04:00
parent 9df55b9c08
commit 623402805b
Signed by: beckermj
GPG Key ID: 24F8DAA73DCB2C8F

View File

@ -55,7 +55,7 @@ namespace MBS.Core.Collections.Generic
return ((List<T>)(cacheOfT[obj][typeof(T)])).ToArray();
}
public static void AddRange<T>(this IList<T> list, IEnumerable<T> items)
public static void AddRange<T>(this ICollection<T> list, IEnumerable<T> items)
{
foreach (T item in items)
{