mirror of
https://github.com/TeamOctolings/Octobot.git
synced 2025-04-29 02:29:55 +03:00
Resolve build errors
Signed-off-by: Octol1ttle <l1ttleofficial@outlook.com>
This commit is contained in:
parent
4c31ebf826
commit
26d7777577
5 changed files with 21 additions and 12 deletions
|
@ -89,6 +89,7 @@ public static class Extensions {
|
|||
|
||||
public static TResult? MaxOrDefault<TSource, TResult>(
|
||||
this IEnumerable<TSource> source, Func<TSource, TResult> selector) {
|
||||
return source.Any() ? source.Max(selector) : default;
|
||||
var list = source.ToList();
|
||||
return list.Any() ? list.Max(selector) : default;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue