Adjusted example error message to reflect the situation that causes the error.
This commit is contained in:
parent
a18f59ab88
commit
9a6cb89b8d
|
|
@ -346,8 +346,8 @@ namespace Microsoft.AspNetCore.Routing.Template
|
||||||
{
|
{
|
||||||
// The optional parameter is preceded by something that is not a literal.
|
// The optional parameter is preceded by something that is not a literal.
|
||||||
// Example of error message:
|
// Example of error message:
|
||||||
// "In the segment '{RouteValue}-{param?}', the optional parameter 'param' is preceded
|
// "In the segment '{RouteValue}{param?}', the optional parameter 'param' is preceded
|
||||||
// by an invalid segment '-'. Only a period (.) can precede an optional parameter.
|
// by an invalid segment '{RouteValue}'. Only a period (.) can precede an optional parameter.
|
||||||
context.Error = string.Format(
|
context.Error = string.Format(
|
||||||
Resources.TemplateRoute_OptionalParameterCanbBePrecededByPeriod,
|
Resources.TemplateRoute_OptionalParameterCanbBePrecededByPeriod,
|
||||||
segment.DebuggerToString(),
|
segment.DebuggerToString(),
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue