Fix merge

This commit is contained in:
Stephan
2018-11-29 12:48:13 +01:00
parent 146bbcec4b
commit 2c2873492f
2 changed files with 5 additions and 5 deletions

View File

@@ -530,7 +530,7 @@ namespace Umbraco.Core.Composing
// if not caching, or not IDiscoverable, directly get types
if (cache == false || typeof(IDiscoverable).IsAssignableFrom(typeof(T)) == false)
{
_logger.Logger.Debug<TypeLoader>("Running a full, non-cached, scan for type {TypeName} (slow).", typeof(T).FullName);
_logger.Debug<TypeLoader>("Running a full, non-cached, scan for type {TypeName} (slow).", typeof(T).FullName);
return GetTypesInternal(
typeof (T), null,
@@ -574,7 +574,7 @@ namespace Umbraco.Core.Composing
// if not caching, or not IDiscoverable, directly get types
if (cache == false || typeof(IDiscoverable).IsAssignableFrom(typeof(T)) == false)
{
_logger.Logger.Debug<TypeLoader>("Running a full, non-cached, scan for type {TypeName} / attribute {AttributeName} (slow).", typeof(T).FullName, typeof(TAttribute).FullName);
_logger.Debug<TypeLoader>("Running a full, non-cached, scan for type {TypeName} / attribute {AttributeName} (slow).", typeof(T).FullName, typeof(TAttribute).FullName);
return GetTypesInternal(
typeof (T), typeof (TAttribute),
@@ -617,7 +617,7 @@ namespace Umbraco.Core.Composing
if (cache == false)
{
_logger.Logger.Debug<TypeLoader>("Running a full, non-cached, scan for types / attribute {AttributeName} (slow).", typeof(TAttribute).FullName);
_logger.Debug<TypeLoader>("Running a full, non-cached, scan for types / attribute {AttributeName} (slow).", typeof(TAttribute).FullName);
}
return GetTypesInternal(

View File

@@ -71,11 +71,11 @@ namespace Umbraco.Web.Composing.Composers
// scan and register every UmbracoApiController in everything (UmbracoApiController is IDiscoverable and IHttpController)
var nonUmbracoWebApiControllers = composition.TypeLoader.GetTypes<UmbracoApiController>().Where(x => x.Assembly != umbracoWebAssembly);
composition.RegisterControllers(nonUmbracoWebApiControllers);
return composition;
}
private static void RegisterControllers<TController>(this Composition composition, IEnumerable<Type> controllerTypes)
private static void RegisterControllers(this Composition composition, IEnumerable<Type> controllerTypes)
{
foreach (var controllerType in controllerTypes)
composition.Register(controllerType, Lifetime.Request);