This commit is contained in:
Ryan Nowak 2019-04-17 14:37:27 -07:00
parent 10d70c5c9e
commit 6074daacae
1 changed files with 1 additions and 2 deletions

View File

@ -107,8 +107,7 @@ namespace Microsoft.AspNetCore.Mvc.RazorPages.Infrastructure
"{ " + string.Join(", ", metadata.Values.Select(kvp => $"{kvp.Key}: {kvp.Value}")) + " }.");
}
// It should not be possible to have more than one result for pages.
Debug.Assert(endpoints.Count == 1);
// It is possible to have more than one result for pages but they are equivalent.
var compiled = await _loader.LoadAsync(endpoints[0].Metadata.GetMetadata<PageActionDescriptor>());
var replacement = compiled.Endpoint;