Skip to content

Commit 042f2d7

Browse files
authored
Merge pull request rails#52444 from dijonkitchen/patch-1
[ci skip] docs: use `as_json` per method instead of `to_json`
2 parents bba9cba + 2329975 commit 042f2d7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

activesupport/lib/active_support/time_with_zone.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,11 +157,11 @@ def xmlschema(fraction_digits = 0)
157157
# to +false+.
158158
#
159159
# # With ActiveSupport::JSON::Encoding.use_standard_json_time_format = true
160-
# Time.utc(2005,2,1,15,15,10).in_time_zone("Hawaii").to_json
160+
# Time.utc(2005,2,1,15,15,10).in_time_zone("Hawaii").as_json
161161
# # => "2005-02-01T05:15:10.000-10:00"
162162
#
163163
# # With ActiveSupport::JSON::Encoding.use_standard_json_time_format = false
164-
# Time.utc(2005,2,1,15,15,10).in_time_zone("Hawaii").to_json
164+
# Time.utc(2005,2,1,15,15,10).in_time_zone("Hawaii").as_json
165165
# # => "2005/02/01 05:15:10 -1000"
166166
def as_json(options = nil)
167167
if ActiveSupport::JSON::Encoding.use_standard_json_time_format

0 commit comments

Comments
 (0)