fix file uploads for non-plain-text files.