Merge pull request #2759 from MediaBrowser/dev

Dev
release-10.1.0
Luke 8 years ago committed by GitHub
commit e6da6fcf68

@ -557,7 +557,7 @@ namespace Emby.Common.Implementations
/// <param name="assembly">The assembly.</param> /// <param name="assembly">The assembly.</param>
/// <returns>IEnumerable{Type}.</returns> /// <returns>IEnumerable{Type}.</returns>
/// <exception cref="System.ArgumentNullException">assembly</exception> /// <exception cref="System.ArgumentNullException">assembly</exception>
protected IEnumerable<Type> GetTypes(Assembly assembly) protected List<Type> GetTypes(Assembly assembly)
{ {
if (assembly == null) if (assembly == null)
{ {
@ -569,21 +569,24 @@ namespace Emby.Common.Implementations
// This null checking really shouldn't be needed but adding it due to some // This null checking really shouldn't be needed but adding it due to some
// unhandled exceptions in mono 5.0 that are a little hard to hunt down // unhandled exceptions in mono 5.0 that are a little hard to hunt down
var types = assembly.GetTypes() ?? new Type[] { }; var types = assembly.GetTypes() ?? new Type[] { };
return types.Where(t => t != null); return types.Where(t => t != null).ToList();
} }
catch (ReflectionTypeLoadException ex) catch (ReflectionTypeLoadException ex)
{ {
if (ex.LoaderExceptions != null) if (ex.LoaderExceptions != null)
{ {
foreach (var loaderException in ex.LoaderExceptions) foreach (var loaderException in ex.LoaderExceptions)
{
if (loaderException != null)
{ {
Logger.Error("LoaderException: " + loaderException.Message); Logger.Error("LoaderException: " + loaderException.Message);
} }
} }
}
// If it fails we can still get a list of the Types it was able to resolve // If it fails we can still get a list of the Types it was able to resolve
var types = ex.Types ?? new Type[] { }; var types = ex.Types ?? new Type[] { };
return types.Where(t => t != null); return types.Where(t => t != null).ToList();
} }
catch (Exception ex) catch (Exception ex)
{ {

@ -1,6 +1,5 @@
NZ-G,1 NZ-G,1
NZ-PG,5 NZ-PG,5
NZ-M,9
NZ-R13,7 NZ-R13,7
NZ-R15,8 NZ-R15,8
NZ-R16,9 NZ-R16,9
@ -8,3 +7,5 @@ NZ-R18,10
NZ-RP13,7 NZ-RP13,7
NZ-RP16,9 NZ-RP16,9
NZ-R,10 NZ-R,10
NZ-M,10
NZ-MA,10

@ -1,3 +1,3 @@
using System.Reflection; using System.Reflection;
[assembly: AssemblyVersion("3.2.25.6")] [assembly: AssemblyVersion("3.2.25.7")]

Loading…
Cancel
Save