Fixed #7748: now upload and register commands don't need to force the encoding anymore : DistributionMetada returns utf8 strings

This commit is contained in:
Tarek Ziadé 2010-01-24 00:33:32 +00:00
parent aa98058cc4
commit f14c7fc33d
6 changed files with 28 additions and 19 deletions

View file

@ -266,7 +266,6 @@ Your selection [default 1]: ''', log.INFO)
if type(value) not in (type([]), type( () )):
value = [value]
for value in value:
value = unicode(value).encode("utf-8")
body.write(sep_boundary)
body.write('\nContent-Disposition: form-data; name="%s"'%key)
body.write("\n\n")

View file

@ -145,7 +145,7 @@ class upload(PyPIRCCommand):
value = value[1]
else:
fn = ""
value = str(value)
body.write(sep_boundary)
body.write('\nContent-Disposition: form-data; name="%s"'%key)
body.write(fn)