diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-08-11 13:14:32 -0700 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-08-11 13:14:32 -0700 |
commit | 8208d088a4bba794dbf5a0d5b39e1732edc2aec4 (patch) | |
tree | 66f2037f4d997f78e587d08cd9eba84e07139f75 /lib/chef/http | |
parent | c6659b70deb4b1f81bc5c20ed237b7637ff20930 (diff) | |
download | chef-8208d088a4bba794dbf5a0d5b39e1732edc2aec4.tar.gz |
specs and lazying net-http client building
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'lib/chef/http')
-rw-r--r-- | lib/chef/http/basic_client.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/chef/http/basic_client.rb b/lib/chef/http/basic_client.rb index 921a28cad0..460744ea2a 100644 --- a/lib/chef/http/basic_client.rb +++ b/lib/chef/http/basic_client.rb @@ -45,7 +45,10 @@ class Chef @url = url @ssl_policy = opts[:ssl_policy] || DefaultSSLPolicy @keepalives = opts[:keepalives] || false - @http_client = build_http_client + end + + def http_client + @http_client ||= build_http_client end def host |