mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
remove string literal concatenation
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
acd82f6e24
commit
db1f7079b6
16 changed files with 35 additions and 44 deletions
|
@ -186,9 +186,7 @@ class Net::HTTPGenericRequest
|
|||
if filename
|
||||
filename = quote_string(filename, charset)
|
||||
type = h[:content_type] || 'application/octet-stream'
|
||||
buf << "Content-Disposition: form-data; " \
|
||||
"name=\"#{key}\"; filename=\"#{filename}\"\r\n" \
|
||||
"Content-Type: #{type}\r\n\r\n"
|
||||
buf << "Content-Disposition: form-data; name=\"#{key}\"; filename=\"#{filename}\"\r\nContent-Type: #{type}\r\n\r\n"
|
||||
if !out.respond_to?(:write) || !value.respond_to?(:read)
|
||||
# if +out+ is not an IO or +value+ is not an IO
|
||||
buf << (value.respond_to?(:read) ? value.read : value)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue