diff options
Diffstat (limited to 'app/validators/same_project_association_validator.rb')
-rw-r--r-- | app/validators/same_project_association_validator.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/validators/same_project_association_validator.rb b/app/validators/same_project_association_validator.rb index 2af2a21fa9a..2fcc369b6ef 100644 --- a/app/validators/same_project_association_validator.rb +++ b/app/validators/same_project_association_validator.rb @@ -16,6 +16,6 @@ class SameProjectAssociationValidator < ActiveModel::EachValidator def validate_each(record, attribute, value) return if record.project == value&.project - record.errors[attribute] << 'must associate the same project' + record.errors.add(attribute, 'must associate the same project') end end |