mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-04-12 12:07:05 +00:00
refactor: Tidying
This commit is contained in:
parent
086aee8167
commit
4bc6258b62
2 changed files with 4 additions and 8 deletions
|
|
@ -42,15 +42,10 @@ namespace ICD.Common.Utils.Extensions
|
||||||
if (predicate == null)
|
if (predicate == null)
|
||||||
throw new ArgumentNullException("predicate");
|
throw new ArgumentNullException("predicate");
|
||||||
|
|
||||||
T output = defaultItem;
|
|
||||||
|
|
||||||
foreach (T item in extends.Where(predicate))
|
foreach (T item in extends.Where(predicate))
|
||||||
{
|
return item;
|
||||||
output = item;
|
|
||||||
break;
|
return defaultItem;
|
||||||
}
|
|
||||||
|
|
||||||
return output;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
|
|
@ -544,6 +544,7 @@ namespace ICD.Common.Utils
|
||||||
{
|
{
|
||||||
if (string.IsNullOrEmpty(text))
|
if (string.IsNullOrEmpty(text))
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
string trimmed = text.Trim();
|
string trimmed = text.Trim();
|
||||||
return trimmed.Length == 0;
|
return trimmed.Length == 0;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue