Allow chunked uploads together with max_number_of_files setting. Closes #2899
Merge branch 'master' into gh-pages