diff options
author | tylercloke <tylercloke@gmail.com> | 2015-06-04 12:23:55 -0700 |
---|---|---|
committer | tylercloke <tylercloke@gmail.com> | 2015-06-05 13:47:44 -0700 |
commit | 58048d42caeadc290876a02aaec7eec6f305920a (patch) | |
tree | ea9743fc860b69f2c4c20bb26b7f58a5d2f6f44f /lib/chef/knife/user_edit.rb | |
parent | 4f2400c8cce57e68f14cb9d4b756ab82b23dd69d (diff) | |
download | chef-58048d42caeadc290876a02aaec7eec6f305920a.tar.gz |
Better API version error handling helper code.
Renamed Chef::Mixin::ApiVersionRequestHandling.handle_version_http_exception -> server_client_api_version_intersection and made it do much more useful / sane things. See comments for details.
Diffstat (limited to 'lib/chef/knife/user_edit.rb')
-rw-r--r-- | lib/chef/knife/user_edit.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/chef/knife/user_edit.rb b/lib/chef/knife/user_edit.rb index 5bed51a1cc..dd2fc02743 100644 --- a/lib/chef/knife/user_edit.rb +++ b/lib/chef/knife/user_edit.rb @@ -41,6 +41,9 @@ EOF end def run_osc_11_user_edit + # run osc_user_create with our input + ARGV.delete("user") + ARGV.unshift("osc_user") Chef::Knife.run(ARGV, Chef::Application::Knife.options) end @@ -62,12 +65,7 @@ EOF # forward to deprecated command if original_user["username"].nil? ui.warn(osc_11_warning) - - # run osc_user_create with our input - ARGV.delete("user") - ARGV.unshift("osc_user") run_osc_11_user_edit - else # EC / CS 12 user create edited_user = edit_data(original_user) if original_user != edited_user |