From: Urban Nilsson Date: 2003-06-07T02:30:55+09:00 Subject: Re: Ruby 1.8.0 net/http bug Thanks for the help everybody! /U torsdagen den 5 juni 2003 kl 20.35 skrev Dave Thomas: > Hal E. Fulton wrote: > >>> >>> resp, data = h.get('/index.html', nil) >>> >>> try adding this line: >>> >>> data = resp.data if data.nil? >>> >>> That should make your code compatible with both versions of net/http. >> Ah, that's a good idea. > > Even better perhaps would be > > class Net::HTTPOK > def to_ary > return self, body > end > end > > That way all original code should still work unchanged. > > Is this worth an RCR? > > > Cheers > > > > Dave > > > ---- Urban Nilsson 'What we in the West call "bugs", the Japanese call "spoilage". I find this nomenclature honest and refreshing. "Bug" implies that the problem is some independent agent, when in fact the problem is the "spoiled" code itself.' -- Handy Vandal