mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-02-11 02:35:05 +00:00
Fixing code smell
This commit is contained in:
@@ -41,9 +41,15 @@ namespace ICD.Common.Utils.Extensions
|
||||
if (predicate == null)
|
||||
throw new ArgumentNullException("predicate");
|
||||
|
||||
T output = defaultItem;
|
||||
|
||||
foreach (T item in extends.Where(predicate))
|
||||
return item;
|
||||
return defaultItem;
|
||||
{
|
||||
output = item;
|
||||
break;
|
||||
}
|
||||
|
||||
return output;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user