Should resource_feeder render_rss_feed_for choke on date (instead of datetime)

I guess I'll work around it with a lamda and a to_time, for now, but to_s(:rfc822) exists in the rails time extensions, but not the date extensions, so if you try to use a date field for pub_date it chokes. My uncertainty is if to_s(:rfc822) should be added to Date (do a to_time, first?) or if resource_feeder should check before doing the to_s(:rfc822).

Please ignore. I still think it's a cryptic error to throw on a nil, but there was a mistake in my code/data. to_s(:rfc822) works fine on a date field, as long as it isn't null/nil.

I wonder if nil.to_s should be extended to accept an optional parameter and still throw the nil exception, to make errors on nil.to_s with the Rails extensions less obscure?

I made a tiny patch (with tests of course) that calls to_time before to_s(:rfc822). This means if pub_date is just a date, not a full datetime, the feed will still be valid. As a side-effect, you get a less cryptic nil error.

The patch also fixes a failing test on resource_feeder, at least on my OS X system (running edge of course): test_should_allow_content_encoded_for_items