1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

fixing the ternary operation where the logic is very confusing.

[#5136 state:resolved]

Signed-off-by: José Valim <jose.valim@gmail.com>
This commit is contained in:
Neeraj Singh 2010-07-17 16:08:17 -04:00 committed by José Valim
parent 4a0d7c1a43
commit 1f499e6d4c

View file

@ -800,7 +800,8 @@ module ActionView
start = options.delete(:start) || 0
stop = options.delete(:end) || 59
step = options.delete(:step) || 1
leading_zeros = options.delete(:leading_zeros).nil? ? true : false
options.reverse_merge!({:leading_zeros => true})
leading_zeros = options.delete(:leading_zeros)
select_options = []
start.step(stop, step) do |i|