update file upload method