From c297e8a97f41221c0a6cfd5f3aee89589811d47c Mon Sep 17 00:00:00 2001 From: cedricnjanga Date: Thu, 15 Mar 2018 06:57:35 -0700 Subject: Refs #6139 Change Min max values validation concern to allowed float values --- app/models/generic_attribute_control/min_max.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'app/models/generic_attribute_control') diff --git a/app/models/generic_attribute_control/min_max.rb b/app/models/generic_attribute_control/min_max.rb index 18873b683..bab900f0e 100644 --- a/app/models/generic_attribute_control/min_max.rb +++ b/app/models/generic_attribute_control/min_max.rb @@ -1,9 +1,7 @@ module GenericAttributeControl class MinMax < ComplianceControl store_accessor :control_attributes, :minimum, :maximum, :target - - validates_numericality_of :minimum, allow_nil: true, greater_than_or_equal_to: 0 - validates_numericality_of :maximum, allow_nil: true, greater_than_or_equal_to: 0 + validates :target, presence: true include MinMaxValuesValidation -- cgit v1.2.3