Skip to content

Commit

Permalink
change for Nick's review, continue
Browse files Browse the repository at this point in the history
  • Loading branch information
Bo Yao committed Jun 21, 2017
1 parent 30f089b commit c6f529f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/gems/pending/appliance_console/key_configuration.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ def ask_question_loop

def activate
if !key_exist? || force
success_get_new = get_new_key
if success_get_new
if get_new_key
save_new_key
else
remove_new_key_if_any
Expand All @@ -68,7 +67,7 @@ def activate

def save_new_key
FileUtils.mv(NEW_KEY_FILE, KEY_FILE, :force => true)
rescue StandardError => e
rescue => e
say("Failed to overwrite original key, original key kept. #{e.message}")
return false
end
Expand Down

0 comments on commit c6f529f

Please sign in to comment.