(rubocop) Fix Style/IfUnlessModifier

This commit is contained in:
Tim Sharpe 2019-02-03 15:40:17 +11:00
parent 426e9ce96b
commit 6e1f626d7b
4 changed files with 19 additions and 57 deletions

View file

@ -300,9 +300,7 @@ class Vmfloaty
hostname = args[0]
snapshot_sha = args[1] || options.snapshot
if args[1] && options.snapshot
STDERR.puts "Two snapshot arguments were given....using snapshot #{snapshot_sha}"
end
STDERR.puts "Two snapshot arguments were given....using snapshot #{snapshot_sha}" if args[1] && options.snapshot
begin
revert_req = service.revert(verbose, hostname, snapshot_sha)
@ -419,9 +417,7 @@ class Vmfloaty
host_os = args.first
if args.length > 1
STDERR.puts "Can't ssh to multiple hosts; Using #{host_os} only..."
end
STDERR.puts "Can't ssh to multiple hosts; Using #{host_os} only..." if args.length > 1
service.ssh(verbose, host_os, use_token)
exit 0