Make a CalculateSuggestedAmount.get_bracket_by_amount slightly more efficient
This commit is contained in:
parent
fbc3d8e51d
commit
9a9c29a0d8
1 changed files with 1 additions and 1 deletions
|
@ -79,6 +79,6 @@ module CalculateSuggestedAmounts
|
|||
end
|
||||
|
||||
def self.get_bracket_by_amount(amount)
|
||||
BRACKETS.select { |i| i[:range].cover?(amount) }.first
|
||||
BRACKETS.detect { |i| i[:range].cover?(amount) }
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue