fixed problems in UG uploading and downloading
Merge branch 'master' into staging