When I have a web API method with a signature like this:
public async void Post()
I get an exception that says:
"Unexpected end of MIME multipart stream. MIME multipart message is not complete."
when reading the multipart data with this line:
await Request.Content.ReadAsMultipartAsync(provider);
However when I change the method into:
public async Task<Boolean> Post()
returning a Task with any type (in this case bool) everything works fine.
public async void Post()
I get an exception that says:
"Unexpected end of MIME multipart stream. MIME multipart message is not complete."
when reading the multipart data with this line:
await Request.Content.ReadAsMultipartAsync(provider);
However when I change the method into:
public async Task<Boolean> Post()
returning a Task with any type (in this case bool) everything works fine.