halorgium / rack-client

A client wrapper around a rack app or live-http
http://halorgium.github.com/rack-client
MIT License
99 stars 28 forks source link

1.8.7 vs. 1.9.2 compat fix when seeing if a request body can be `rack.input` #10

Closed danp closed 13 years ago

danp commented 13 years ago

Use rewind as the magic method to determine if a body is ready to be rack.input.

Using each has 1.8.7 vs. 1.9.2 problems as in 1.8.7 String responds to each but not rewind as some things expect.

benburkert commented 13 years ago

I reworked the ensure_acceptable_input method to strictly follow the rack spec. Thanks for the patch!