method

attribute_names

Importance_1
v7.1.3.2 - Show latest stable - 0 notes - Class: ActiveModel::Errors
attribute_names() public

Returns all error attribute names

person.errors.messages        # => {:name=>["cannot be nil", "must be specified"]}
person.errors.attribute_names # => [:name]
Show source
Register or log in to add new notes.