if we only get the filename, but not the content-type, guess ct based on the filename