Class: Float
Relationships & Source Files | |
Inherits: | Object |
Defined in: | activesupport/lib/active_support/core_ext/object/json.rb |
Instance Method Summary
-
#as_json(options = nil)
Internal use only
Encoding Infinity or NaN to JSON should return “null”.
Instance Method Details
#as_json(options = nil)
This method is for internal use only.
Encoding Infinity or NaN to JSON should return “null”. The default returns “Infinity” or “NaN” which are not valid JSON.
# File 'activesupport/lib/active_support/core_ext/object/json.rb', line 119
def as_json( = nil) # :nodoc: finite? ? self : nil end