fixed uploading file to server