From c70135807ed786e6c9e18a35cc83ac6007450ca2 Mon Sep 17 00:00:00 2001 From: Jonathan Roes Date: Fri, 20 Jan 2012 10:12:05 -0500 Subject: document `:raise` option support for several helpers [ci skip] --- actionpack/lib/action_view/helpers/number_helper.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'actionpack') diff --git a/actionpack/lib/action_view/helpers/number_helper.rb b/actionpack/lib/action_view/helpers/number_helper.rb index a325eb59dc..eda16903b0 100644 --- a/actionpack/lib/action_view/helpers/number_helper.rb +++ b/actionpack/lib/action_view/helpers/number_helper.rb @@ -265,6 +265,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, raises +InvalidNumberError+ when the argument is invalid. # # ==== Examples # number_with_precision(111.2345) # => 111.235 @@ -344,6 +345,7 @@ module ActionView # * :delimiter - Sets the thousands delimiter (defaults to ""). # * :strip_insignificant_zeros - If +true+ removes insignificant zeros after the decimal separator (defaults to +true+) # * :prefix - If +:si+ formats the number using the SI prefix (defaults to :binary) + # * :raise - If true, raises +InvalidNumberError+ when the argument is invalid. # ==== Examples # number_to_human_size(123) # => 123 Bytes # number_to_human_size(1234) # => 1.21 KB @@ -425,6 +427,7 @@ module ActionView # * *integers*: :unit, :ten, :hundred, :thousand, :million, :billion, :trillion, :quadrillion # * *fractionals*: :deci, :centi, :mili, :micro, :nano, :pico, :femto # * :format - Sets the format of the output string (defaults to "%n %u"). The field types are: + # * :raise - If true, raises +InvalidNumberError+ when the argument is invalid. # # %u The quantifier (ex.: 'thousand') # %n The number -- cgit v1.2.3