The issue here is that a model state error is added with the model name 'doubled'. This is on a fairly obscure code path and the code dates back to the original WSR git checkin of webapi. There are no wsr tests that verify this behavior. The cause here is that our 'greedy' model binders (like FromHeaderModelBinder) return 'true' whether or not they successfully found a model, because they don't want other model binders to run. This also has an effect on the validation system. That means that validators will run and attempt to validate the model (which may be null). That's that rare case where we get to this code path. |
||
|---|---|---|
| .. | ||
| Binders | ||
| Internal | ||
| Metadata | ||
| Properties | ||
| Utils | ||
| Validation | ||
| ValueProviders | ||
| BindAttributeTest.cs | ||
| Microsoft.AspNet.Mvc.ModelBinding.Test.kproj | ||
| ModelBindingContextTest.cs | ||
| Resources.resx | ||
| SimpleTypeExcludeFilterTest.cs | ||
| project.json | ||