errorsFor (attribute) Array
Returns errors for a given attribute
var user = store.createRecord('user', { username: 'tomster', email: 'invalidEmail' }); user.save().catch(function(){ user.get('errors').errorsFor('email'); // returns: // [{attribute: "email", message: "Doesn't look like a valid email."}] });
Parameters:
-
attribute
String
Returns:
-
Array
Please login to continue.