Fixing invocation results for tasks whose result is `VoidTaskResult`
This commit is contained in:
parent
5f23231d9b
commit
8d03c014fb
|
|
@ -144,8 +144,11 @@ namespace Microsoft.AspNetCore.SignalR
|
|||
if (resultTask != null)
|
||||
{
|
||||
await resultTask;
|
||||
var property = resultTask.GetType().GetProperty("Result");
|
||||
invocationResult.Result = property?.GetValue(resultTask);
|
||||
if (methodInfo.ReturnType.GetTypeInfo().IsGenericType)
|
||||
{
|
||||
var property = resultTask.GetType().GetProperty("Result");
|
||||
invocationResult.Result = property?.GetValue(resultTask);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue