Odd deprecation warnings...

Eric Nielsen wrote:

I have come across a few deprecation warnings that I think are in error and I'm not sure how to resolve them.

The first set are regarding the "type" column of an STI hierarchy conficting with Object#type: The warning message in particular is:

/usr/local/lib/ruby/gems/1.8/gems/actionpack-1.12.5.5618/lib/action_view/helpers/form_helper.rb:349:

warning: Object#type is deprecated; use Object#class

and is triggered from calling

<%= f.radio_button :type, "Personal" -%> <%= f.radio_button :type, "Shared" -%>

within a form_for block with an instance of the base class of the STI hierarchy bound to the model variable. (This is step one in a two step wizard for creating accounts. In step two the display is customized with the appropriate fieds based on the type selected in step one.)

http://article.gmane.org/gmane.comp.lang.ruby.rails/84823

The second set of warnings deal with "find_all" when used with a block as a filter over a collection. I'm not trying to use the find_all => find :all finder. I need to generate a list of all elements in the collection that meet a rather complicated set of condiftions that's calculated in the model (doesn't hit the DB). Is there a way to call the underlying find_all with a block on an enumerable collection of AR objects without triggering the find_all=>find :all deprecation warning?

http://article.gmane.org/gmane.comp.lang.ruby.rails/100514