Update code example to follow rubocop recommendations

Just for consistency with what you would see elsewhere in the codebase
This commit is contained in:
Andy Allan 2021-03-17 15:37:55 +00:00
parent cb422209a4
commit 0d313a9e03

View file

@ -28,7 +28,7 @@ If you create a user by signing up to your local website, you need to confirm th
```
$ bundle exec rails console
>> user = User.find_by_display_name("My New User Name")
>> user = User.find_by(:display_name => "My New User Name")
=> #[ ... ]
>> user.status = "active"
=> "active"
@ -43,7 +43,7 @@ To give administrator or moderator permissions:
```
$ bundle exec rails console
>> user = User.find_by_display_name("My New User Name")
>> user = User.find_by(:display_name => "My New User Name")
=> #[ ... ]
>> user.roles.create(:role => "administrator", :granter_id => user.id)
=> #[ ... ]