summaryrefslogtreecommitdiff
path: root/lib/chef/knife/bootstrap/train_connector.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/knife/bootstrap/train_connector.rb')
-rw-r--r--lib/chef/knife/bootstrap/train_connector.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/knife/bootstrap/train_connector.rb b/lib/chef/knife/bootstrap/train_connector.rb
index 8a1e5863bb..a220ece5bc 100644
--- a/lib/chef/knife/bootstrap/train_connector.rb
+++ b/lib/chef/knife/bootstrap/train_connector.rb
@@ -285,7 +285,7 @@ class Chef
# Train.unpack_target_from_uri only works for complete URIs in
# form of proto://[user[:pass]@]host[:port]/
# So we'll add the protocol prefix if it's not supplied.
- uri_to_check = if URI.regexp.match(uri)
+ uri_to_check = if URI::DEFAULT_PARSER.make_regexp.match(uri)
uri
else
"#{default_protocol}://#{uri}"