Merge pull request #697 from MVUG/upload-fixes-2.1

Fixed bug in Upload library
tmp_path does not exists, should be tmp_name.