diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-11 16:12:49 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-11 16:12:49 -0800 |
commit | 002ef48ab082fc8f0767fb37c5b94471a8fd0185 (patch) | |
tree | 865e2a2758c93967f926110f3e0eebe93d303f81 /lib/chef/application | |
parent | 6ca21c9ce206f1ada1c12a02afb46e3f1625a321 (diff) | |
parent | 37e02399a6e1dd281808a556f1420f8cf6e846fd (diff) | |
download | chef-002ef48ab082fc8f0767fb37c5b94471a8fd0185.tar.gz |
Merge pull request #4541 from chef/lcg/chefstyle-batch
fix a batch of cops
Diffstat (limited to 'lib/chef/application')
-rw-r--r-- | lib/chef/application/knife.rb | 2 | ||||
-rw-r--r-- | lib/chef/application/windows_service.rb | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/chef/application/knife.rb b/lib/chef/application/knife.rb index 849a011ab3..4a39ba5ba1 100644 --- a/lib/chef/application/knife.rb +++ b/lib/chef/application/knife.rb @@ -167,7 +167,7 @@ class Chef::Application::Knife < Chef::Application if no_command_given? print_help_and_exit(1, NO_COMMAND_GIVEN) elsif no_subcommand_given? - if (want_help? || want_version?) + if want_help? || want_version? print_help_and_exit(0) else print_help_and_exit(2, NO_COMMAND_GIVEN) diff --git a/lib/chef/application/windows_service.rb b/lib/chef/application/windows_service.rb index b955dd31b8..a9f7664e4f 100644 --- a/lib/chef/application/windows_service.rb +++ b/lib/chef/application/windows_service.rb @@ -74,7 +74,7 @@ class Chef # Set the initial timeout to splay sleep time timeout = rand Chef::Config[:splay] - while running? do + while running? # Grab the service_action_mutex to make a chef-client run @service_action_mutex.synchronize do begin @@ -310,7 +310,7 @@ class Chef when /^(http|https):\/\// Chef::HTTP.new("").streaming_request(config[:config_file]) { |f| apply_config(f.path) } else - ::File::open(config[:config_file]) { |f| apply_config(f.path) } + ::File.open(config[:config_file]) { |f| apply_config(f.path) } end rescue Errno::ENOENT => error Chef::Log.warn("*****************************************") |