instance method messages

Ruby on Rails 6.1.7.10

Since v6.1.7.10

Available in: v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Signature

messages()

Returns a Hash of attributes with an array of their error messages.

Updating this hash would still update errors state for backward compatibility, but this behavior is deprecated.

Source
# File activemodel/lib/active_model/errors.rb, line 340
    def messages
      DeprecationHandlingMessageHash.new(self)
    end

Defined in activemodel/lib/active_model/errors.rb line 340 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveModel::Errors

Type at least 2 characters to search.

↑↓ navigate · open · esc close