ensure the proper temp directory is used
Improving and expanding upload policies