tomaka / rouille

Web framework in Rust
Apache License 2.0
1.09k stars 105 forks source link

Parse array of values from form data #163

Open I3ck opened 6 years ago

I3ck commented 6 years ago

I can't find a solution for parsing an array of values such as:

Form parameters

foo = ["a", "b", "c"]
bar = true

In rouille

let data = try_or_400!(post_input!(request, {
    foo : Vec<String>,
    bar: bool
}));

bar and any "non-vector" types bind correctly, foo will always be empty.
I also tried renaming foo to foo[] on the client side.
How can I bind such values?

tomaka commented 6 years ago

The Vec is supposed to work.