lib/sunrise/file_upload/request.rb in sunrise-file-upload-0.1.3 vs lib/sunrise/file_upload/request.rb in sunrise-file-upload-0.1.4
- old
+ new
@@ -13,10 +13,10 @@
@env['RAW_POST_DATA']
end
def body
if raw_post = @env['RAW_POST_DATA']
- raw_post.force_encoding(Encoding::BINARY) if raw_post.respond_to?(:force_encoding)
+ raw_post = raw_post.force_encoding(Encoding::BINARY) if raw_post.respond_to?(:force_encoding)
StringIO.new(raw_post)
else
@env['rack.input']
end
end