1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Merge pull request #42114 from adityapandit17/guides_patch

Fixed guide example with rails api docs [ci skip]
This commit is contained in:
Zachary Scott 2021-05-02 10:41:39 +09:00 committed by GitHub
commit bbd6d82dc4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -357,7 +357,7 @@ If you wish to test out some code without changing any data, you can do that by
```bash ```bash
$ bin/rails console --sandbox $ bin/rails console --sandbox
Loading development environment in sandbox (Rails 5.1.0) Loading development environment in sandbox (Rails 7.0.0)
Any modifications you make will be rolled back on exit Any modifications you make will be rolled back on exit
irb(main):001:0> irb(main):001:0>
``` ```

View file

@ -722,7 +722,7 @@ Ruby instruction to be executed -- in this case, Active Support's `week` method.
49: 49:
50: # Returns a Duration instance matching the number of weeks provided. 50: # Returns a Duration instance matching the number of weeks provided.
51: # 51: #
52: # 2.weeks # => 14 days 52: # 2.weeks # => 2 weeks
53: def weeks 53: def weeks
=> 54: ActiveSupport::Duration.weeks(self) => 54: ActiveSupport::Duration.weeks(self)
55: end 55: end