title: Bad Request error with File Upload Spring MVC 4
body: <p>I've the following scenario where getting bad request on form submit. I am using Spring MVC 4 and submitting the form using jquery ajaxSubmit method.</p>
  
  <p>I have a form with multiple file upload. When I submit the form and if file(s) have been selected, it works perfectly. But if I don't select any file, it throws bad request (400) error and not calling the controller method. </p>
  
  <p>For example: </p>
  
  <pre><code>public class TestPOJO {
         List&lt;MultipartFile&gt; listArray;   
  }
  
  // Controller
  public class MyController extends .. {
  
  
      public ResponseBody fileUplaod(@Model testpojo) {
              //logic to save it to database
      } 
  
  }
  </code></pre>
  
  <p>Not following the exact syntax, but I know programmers can understand from this.</p>
  
  <p>I have debugged the issue and found that it passes List of string instead of List of multipart file when file is not selected. How to avoid this  ? Any pointers?</p>