```ruby
if (user = User.find_by(email: 'abc@example.com'))
user.update(status: 'active')
```
Is it better to do this instead?
user = User.find_by(email: 'abc@example.com')
user.update(status: 'active') if user.present?
a_w•5h ago
```ruby
if (user = User.find_by(email: 'abc@example.com'))
end```
Is it better to do this instead?
```ruby
user = User.find_by(email: 'abc@example.com')
user.update(status: 'active') if user.present?
```