bugfix: handled the options to the upload_file() interface