Sha256: 1040555189999c8484e1ed5d28aa679a35ee41754ca3e26eb7e5a82a0ca9f11c

Contents?: true

Size: 230 Bytes

Versions: 18

Compression:

Stored size: 230 Bytes

Contents

class DefaultChangeValidator < ActiveModel::EachValidator # :nodoc:
  def validate_each(record, attribute, value)
    return unless record.default_changes[attribute]
    record.errors.add(attribute, 'changed by default')
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
csv_row_model-1.0.0.beta2 lib/csv_row_model/validators/default_change_validator.rb
csv_row_model-1.0.0.beta1 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.4.1 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.4.0 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.10 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.9 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.8 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.7 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.6 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.5 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.4 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.3 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.2 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.1 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.3.0 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.2.1 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.1.1 lib/csv_row_model/validators/default_change.rb
csv_row_model-0.1.0 lib/csv_row_model/validators/default_change.rb