lib/twitter_cldr/formatters/numbers/helpers/base.rb in twitter_cldr-1.6.2 vs lib/twitter_cldr/formatters/numbers/helpers/base.rb in twitter_cldr-1.7.0
- old
+ new
@@ -8,10 +8,10 @@
module Numbers
class Base
def interpolate(string, value, orientation = :right)
value = value.to_s
length = value.length
- start, pad = orientation == :left ? [0, :rjust] : [-length, :ljust]
+ start = orientation == :left ? 0 : -length
string = string.dup
string = string.ljust(length, '#') if string.length < length
string[start, length] = value
string.gsub('#', '')
\ No newline at end of file