The reason for this error is, we have two file params, so amazon s3 thinks we trying to send 2 files in the same request.
<%= file_field_tag :file, multiple: false%>
in the form adding a file param, and dropzone adding another file param, There is two solutions for this.
- Quick fix - just simply delete the file_field in the form and everything will just works fine.
- Solution - add a fallback class as below, so that dropzone.js will mute it automatically.
//Like this,
<%= content_tag :div, class: "fallback" do %>
<%= file_field_tag :file, multiple: false%>
<% end %>
When javascript is disabled or not supported, normal input file will show this way.