Skip to content
Myr

string formatting

Before adoption: this commit came in with the history the project adopted, so no landing records it.

#139

authored by Kenneth Reitz · committed by Kenneth Reitz · parent 256c86f · Browse files · 1 file+2 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+2 added−2 removed

  • other:+2 added−2 removed

1 file+2 added−2 removed

modified:requests/utils.py+2 added-2 removed
193 unmodified lines
194 data = ''195 if request.method in ('PUT', 'POST', 'PATCH'):196 #: -d/--data - send specified data in post request.197 if isinstance(request.data, (list, tuple)):198 data = data.join(['-d ' + key + '=' + value + ' ' for key, value in request.data])198 data = data.join(['-d %s=%s ' % (k, v) for (k, v) in request.data])199 elif request._enc_data is not None:200 data = '-d ' + request._enc_data + ' '200 data = '-d %s ' % (request._enc_data)201202 #: Params handled in _build_url203 return curl_cmd + method_opt + data + header + '"' + request._build_url() + '"'