Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab/github_gists_import/importer/gist_importer.rb')
-rw-r--r--lib/gitlab/github_gists_import/importer/gist_importer.rb12
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/gitlab/github_gists_import/importer/gist_importer.rb b/lib/gitlab/github_gists_import/importer/gist_importer.rb
index 71dfe5e2aa5..c2456f83711 100644
--- a/lib/gitlab/github_gists_import/importer/gist_importer.rb
+++ b/lib/gitlab/github_gists_import/importer/gist_importer.rb
@@ -58,11 +58,13 @@ module Gitlab
end
def get_resolved_address
- validated_pull_url, host = Gitlab::UrlBlocker.validate!(gist.git_pull_url,
- schemes: Project::VALID_IMPORT_PROTOCOLS,
- ports: Project::VALID_IMPORT_PORTS,
- allow_localhost: allow_local_requests?,
- allow_local_network: allow_local_requests?)
+ validated_pull_url, host = Gitlab::HTTP_V2::UrlBlocker.validate!(
+ gist.git_pull_url,
+ schemes: Project::VALID_IMPORT_PROTOCOLS,
+ ports: Project::VALID_IMPORT_PORTS,
+ allow_localhost: allow_local_requests?,
+ allow_local_network: allow_local_requests?,
+ deny_all_requests_except_allowed: Gitlab::CurrentSettings.deny_all_requests_except_allowed?)
host.present? ? validated_pull_url.host.to_s : ''
end