adds i18n to residence document error

This commit is contained in:
Juanjo Bazán
2015-09-16 14:42:03 +02:00
committed by Juanjo Bazán
parent 17af8f48c8
commit fe9241c81b
3 changed files with 3 additions and 2 deletions

View File

@@ -30,7 +30,7 @@ class Verification::Residence
end
def document_number_uniqueness
errors.add(:document_number, "Already in use") if User.where(document_number: document_number).any?
errors.add(:document_number, I18n.t('errors.messages.taken')) if User.where(document_number: document_number).any?
end
def residence_in_madrid