Make the "cannot be loaded" warning fire correctly (#729)

Why am I such a bad programmer? Maybe I'm just bad with git. Maybe I'm
just bad in general. Maybe I should resign from programming.
This commit is contained in:
Finite Reality
2017-07-06 00:19:09 +01:00
committed by RogueException
parent b6dcc9e8d8
commit d2afb06942

View File

@@ -24,7 +24,7 @@ namespace Discord.Commands
foreach (var typeInfo in assembly.DefinedTypes)
{
if (typeInfo.IsPublic)
if (typeInfo.IsPublic || typeInfo.IsNestedPublic)
{
if (IsValidModuleDefinition(typeInfo) &&
!typeInfo.IsDefined(typeof(DontAutoLoadAttribute)))
@@ -70,7 +70,7 @@ namespace Discord.Commands
result[typeInfo.AsType()] = module.Build(service);
}
await service._cmdLogger.DebugAsync($"Successfully built and loaded {builtTypes.Count} modules.").ConfigureAwait(false);
await service._cmdLogger.DebugAsync($"Successfully built {builtTypes.Count} modules.").ConfigureAwait(false);
return result;
}