From 4b2b595992821688615b4771bf1939b5186815e8 Mon Sep 17 00:00:00 2001 From: Vijay Dev Date: Wed, 4 Jan 2012 20:18:56 +0530 Subject: copy edits --- actionpack/lib/action_view/helpers/number_helper.rb | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) (limited to 'actionpack/lib/action_view/helpers/number_helper.rb') diff --git a/actionpack/lib/action_view/helpers/number_helper.rb b/actionpack/lib/action_view/helpers/number_helper.rb index 6f6ab49268..736e2cd57b 100644 --- a/actionpack/lib/action_view/helpers/number_helper.rb +++ b/actionpack/lib/action_view/helpers/number_helper.rb @@ -39,8 +39,7 @@ module ActionView # * :extension - Specifies an extension to add to the end of the # generated number. # * :country_code - Sets the country code for the phone number. - # * :raise - If +true+ InvalidNumberError is raised when an invalid - # number is given. + # * :raise - If true, raises +InvalidNumberError+ when the argument is invalid. # # ==== Examples # @@ -53,7 +52,7 @@ module ActionView # number_to_phone(1235551234, :country_code => 1) # => +1-123-555-1234 # number_to_phone("123a456") # => 123a456 # - # number_to_phone("1234a567", :raise => true) # => raise InvalidNumberError + # number_to_phone("1234a567", :raise => true) # => InvalidNumberError # # number_to_phone(1235551234, :country_code => 1, :extension => 1343, :delimiter => ".") # # => +1.123.555.1234 x 1343 @@ -104,8 +103,7 @@ module ActionView # an hyphen to the formatted number given by :format). # Accepts the same fields than :format, except # %n is here the absolute value of the number. - # * :raise - If +true+ InvalidNumberError is raised when an invalid - # number is given. + # * :raise - If true, raises +InvalidNumberError+ when the argument is invalid. # # ==== Examples # @@ -115,7 +113,7 @@ module ActionView # number_to_currency(1234567890.506, :locale => :fr) # => 1 234 567 890,51 € # number_to_currency("123a456") # => $123a456 # - # number_to_currency("123a456", :raise => true) # => raise InvalidNumberError + # number_to_currency("123a456", :raise => true) # => InvalidNumberError # # number_to_currency(-1234567890.50, :negative_format => "(%u%n)") # # => ($1,234,567,890.50) @@ -171,8 +169,7 @@ module ActionView # * :delimiter - Sets the thousands delimiter (defaults to ""). # * :strip_insignificant_zeros - If +true+ removes insignificant zeros after the decimal separator # (defaults to +false+). - # * :raise - If +true+ InvalidNumberError is raised when an invalid - # number is given. + # * :raise - If true, raises +InvalidNumberError+ when the argument is invalid. # # ==== Examples # @@ -184,7 +181,7 @@ module ActionView # number_to_percentage(1000, :locale => :fr) # => 1 000,000% # number_to_percentage("98a") # => 98a% # - # number_to_percentage("98a", :raise => true) # => raise InvalidNumberError + # number_to_percentage("98a", :raise => true) # => InvalidNumberError def number_to_percentage(number, options = {}) return unless number @@ -215,7 +212,7 @@ module ActionView # * :locale - Sets the locale to be used for formatting (defaults to current locale). # * :delimiter - Sets the thousands delimiter (defaults to ","). # * :separator - Sets the separator between the fractional and integer digits (defaults to "."). - # * :raise - If +true+ InvalidNumberError is raised when an invalid. number is given. + # * :raise - If true, raises +InvalidNumberError+ when the argument is invalid. # # ==== Examples # -- cgit v1.2.3