fixes a single vs first check with render route handler when there might be duplicate routes assigned to a controller
This commit is contained in:
@@ -228,8 +228,9 @@ namespace Umbraco.Web.Mvc
|
||||
// If more than one route is found, find one with a matching action
|
||||
if (surfaceRoutes.Count() > 1)
|
||||
{
|
||||
surfaceRoute = surfaceRoutes.SingleOrDefault(x =>
|
||||
x.Defaults["action"].ToString().InvariantEquals(postedInfo.ActionName));
|
||||
surfaceRoute = surfaceRoutes.FirstOrDefault(x =>
|
||||
x.Defaults["action"] != null &&
|
||||
x.Defaults["action"].ToString().InvariantEquals(postedInfo.ActionName));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user