Project

General

Profile

« Previous | Next » 

Revision cabe2c2e

Added by Ohad Levy about 7 years ago

Fixes #19700 - update rubocop rules

The following changes have been made:

- Performance/RedundantMerge:
changes lines such as:
```not_found_message.merge! :message => options```
to:
```not_found_message[:message] = options```

- converts str.match() to str =~ ()
- remove extra whitespaces etc.

View differences:

app/models/compute_resources/foreman/model/ec2.rb
def create_vm(args = { })
args = vm_instance_defaults.merge(args.to_hash.symbolize_keys).deep_symbolize_keys
if (name = args[:name])
args.merge!(:tags => {:Name => name})
args[:tags] = {:Name => name}
end
if (image_id = args[:image_id])
image = images.find_by_uuid(image_id.to_s)

Also available in: Unified diff