Hosting: Throw if startup method isn't void-returning.
This commit is contained in:
parent
aa4dfffd84
commit
4077c03a7b
|
|
@ -65,6 +65,11 @@ namespace Microsoft.AspNet.Hosting.Startup
|
|||
throw new Exception("TODO: Configuration method not found");
|
||||
}
|
||||
|
||||
if (methodInfo.ReturnType != typeof(void))
|
||||
{
|
||||
throw new Exception("TODO: Configuration method isn't void-returning.");
|
||||
}
|
||||
|
||||
object instance = null;
|
||||
if (!methodInfo.IsStatic)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue