Skip to content

Commit

Permalink
unless uuid vs if uuid.nil?
Browse files Browse the repository at this point in the history
Signed-off-by: Miah Johnson <miah@chia-pet.org>
  • Loading branch information
miah committed May 29, 2019
1 parent 79fda42 commit 40bdf16
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/train/platforms/detect/helpers/os_common.rb
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ def cisco_show_version

def unix_uuid
uuid = unix_uuid_from_chef
uuid = unix_uuid_from_machine_file if uuid.nil?
uuid = uuid_from_command if uuid.nil?
raise Train::TransportError, "Cannot find a UUID for your node." if uuid.nil?
uuid = unix_uuid_from_machine_file unless uuid
uuid = uuid_from_command unless uuid
raise Train::TransportError, "Cannot find a UUID for your node." unless uuid
uuid
end

Expand Down

0 comments on commit 40bdf16

Please sign in to comment.