Update aspnetcore/mvc/models/model-binding.md
parent
86fed85d8b
commit
0f93c11193
|
@ -342,7 +342,10 @@ For targets that are collections of simple types, model binding looks for matche
|
|||
[a]=1050&[b]=2000&index=a&index=b
|
||||
```
|
||||
|
||||
<!-- STUB: Make same change here -->
|
||||
Avoid binding a parameter or a property named `index` or `Index` if it is adjacent to a collection value. Model binding attempts to use `index` as the index for the collection which might result in incorrect binding. For example, consider the following action:
|
||||
|
||||
```csharp
|
||||
public IActionResult Post(string index, List<Product> products)
|
||||
* The following format is supported only in form data:
|
||||
|
||||
```
|
||||
|
|
Loading…
Reference in New Issue