lib/restfulness/request.rb in restfulness-0.3.4 vs lib/restfulness/request.rb in restfulness-0.3.5

- old
+ new

@@ -108,10 +108,12 @@ def body_to_string unless body.nil? # Sometimes the body can be a StringIO, Tempfile, or some other freakish IO. if body.respond_to?(:read) - body.read + read_body = body.read + body.rewind if body.respond_to?(:rewind) + read_body else body end else ""