summaryrefslogtreecommitdiff
path: root/lib/bundler/source/git
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bundler/source/git')
-rw-r--r--lib/bundler/source/git/git_proxy.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/bundler/source/git/git_proxy.rb b/lib/bundler/source/git/git_proxy.rb
index ae21770306..7555561edd 100644
--- a/lib/bundler/source/git/git_proxy.rb
+++ b/lib/bundler/source/git/git_proxy.rb
@@ -1,7 +1,5 @@
# frozen_string_literal: true
-require "shellwords"
-
module Bundler
class Source
class Git
@@ -224,6 +222,7 @@ module Bundler
end
def check_allowed(command)
+ require "shellwords"
command_with_no_credentials = URICredentialsFilter.credential_filtered_string("git #{command.shelljoin}", uri)
raise GitNotAllowedError.new(command_with_no_credentials) unless allow?
command_with_no_credentials