1
0
Fork 0
mirror of https://github.com/jnunemaker/httparty synced 2023-03-27 23:23:07 -04:00
httparty/spec
Timon Vonk 5a891c4273 'null' and bodies made up out of spaces
The format. helper in Rails calls .to_json on the object in the body.
When using the head helper, it calls to_json on nil, resulting in
"null". Since its a null value, it isn't necessarilly incorrect, but its
debatable whether a HEAD only response should have a body at all.

On the other hand. MultiJSON doesn't parse "null", "  ", nil or an empty
string.

Of course we can also blame Net::HTTP for saying that null in the body
stands for a string with "null". Thats like having a barbeque,
forgetting the meat, but putting some lard on anyway.

So, lets just let HTTParty fix it. Everyone's invited :-)
2011-11-01 15:19:43 +01:00
..
fixtures Update signed certs for longer lasting expiration 2010-10-20 09:49:15 -04:00
httparty 'null' and bodies made up out of spaces 2011-11-01 15:19:43 +01:00
support Refactor redirection handling 2011-01-18 16:19:45 -05:00
httparty_spec.rb net http timeout can also be a float 2011-02-17 10:55:48 -08:00
spec.opts Always include backtrace when running specs 2010-01-29 15:45:36 -05:00
spec_helper.rb Switch to bundler for release management and use hand made gemspec. 2011-04-16 14:43:20 -04:00