mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-30 11:48:26 -07:00
Xbmc Refactored
This commit is contained in:
parent
76fb548ccd
commit
b99e62c5ba
38 changed files with 1501 additions and 1521 deletions
25
NzbDrone.Common/StringExtension.cs
Normal file
25
NzbDrone.Common/StringExtension.cs
Normal file
|
@ -0,0 +1,25 @@
|
|||
using System;
|
||||
using System.Linq;
|
||||
|
||||
namespace NzbDrone.Common
|
||||
{
|
||||
public static class StringExtension
|
||||
{
|
||||
|
||||
public static object NullSafe(this object target)
|
||||
{
|
||||
if (target != null) return target;
|
||||
return "[NULL]";
|
||||
}
|
||||
|
||||
public static string NullSafe(this string target)
|
||||
{
|
||||
return ((object)target).NullSafe().ToString();
|
||||
}
|
||||
|
||||
public static string FirstCharToUpper(this string input)
|
||||
{
|
||||
return input.First().ToString().ToUpper() + String.Join("", input.Skip(1));
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue