aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Common/Extensions/BaseExtensions.cs
diff options
context:
space:
mode:
authorTechywarrior <techywarrior@gmail.com>2013-04-13 11:11:19 -0700
committerTechywarrior <techywarrior@gmail.com>2013-04-13 11:11:19 -0700
commit6b47336da308c77e441b82c6a985db88c6d3ade3 (patch)
tree455a36e52c4ca35e3b38060f96904fa4be5ee854 /MediaBrowser.Common/Extensions/BaseExtensions.cs
parentdc8d9810b7a99bdcbc4959a77750b3cfee1e88b5 (diff)
parent157a53a9f6d88c7f9db2346e42e010fe98734204 (diff)
Merge branch 'master' of https://github.com/MediaBrowser/MediaBrowser
Diffstat (limited to 'MediaBrowser.Common/Extensions/BaseExtensions.cs')
-rw-r--r--MediaBrowser.Common/Extensions/BaseExtensions.cs22
1 files changed, 0 insertions, 22 deletions
diff --git a/MediaBrowser.Common/Extensions/BaseExtensions.cs b/MediaBrowser.Common/Extensions/BaseExtensions.cs
index 9591862e7..b4ad90168 100644
--- a/MediaBrowser.Common/Extensions/BaseExtensions.cs
+++ b/MediaBrowser.Common/Extensions/BaseExtensions.cs
@@ -1,6 +1,4 @@
using System;
-using System.Collections.Generic;
-using System.Linq;
using System.Security.Cryptography;
using System.Text;
using System.Text.RegularExpressions;
@@ -56,26 +54,6 @@ namespace MediaBrowser.Common.Extensions
}
/// <summary>
- /// Helper method for Dictionaries since they throw on not-found keys
- /// </summary>
- /// <typeparam name="T"></typeparam>
- /// <typeparam name="U"></typeparam>
- /// <param name="dictionary">The dictionary.</param>
- /// <param name="key">The key.</param>
- /// <param name="defaultValue">The default value.</param>
- /// <returns>``1.</returns>
- public static U GetValueOrDefault<T, U>(this Dictionary<T, U> dictionary, T key, U defaultValue)
- {
- U val;
- if (!dictionary.TryGetValue(key, out val))
- {
- val = defaultValue;
- }
- return val;
-
- }
-
- /// <summary>
/// Gets the attribute value.
/// </summary>
/// <param name="str">The STR.</param>