Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Cleanup commented code in AR::Errors

#1467

    def full_messages(options = {})
      full_messages = []

      @errors.each_key do |attr|
        @errors[attr].each do |message|
          next unless message

          if attr == "base"
            full_messages << message
          else
            #key = :"activerecord.att.#{@base.class.name.underscore.to_sym}.#{attr}"
            attr_name = @base.class.human_attribute_name(attr)
            full_messages << attr_name + ' ' + message
          end
        end
      end
      full_messages
    end

Guess key = ... stuff was meant for I18n but it is commented out and looks like attr name translation works fine right now.

Reported by Yaroslav Markin · November 25th, 2008 @ 09:43 AM

State: resolved
Milestone: 2.x
Assigned to: nobody
Importance: none

Activity

  1. Repository
    Repository
    • State changed from new to resolved

    (from [276ea48de96a0c4242139ec9323eefb6f254c2a1]) Remove dead commented out code [#1467 Cleanup commented code in AR::Errors state:resolved]

    Signed-off-by: Frederick Cheung frederick.cheung@gmail.com http://github.com/rails/rails/co...

    December 21st, 2008 @ 04:07 PM