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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-03-19 18:09:41 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-03-19 18:09:41 +0300
commit78d8830cec030ff12afed3c8ae1dddec454d0a24 (patch)
treeb5494f60c7d28be787eee7872fd3d99dcbf9f8c8 /app/controllers/import
parent652bd073731b0028641672a75355c7918b5ac116 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/controllers/import')
-rw-r--r--app/controllers/import/gitlab_projects_controller.rb13
1 files changed, 1 insertions, 12 deletions
diff --git a/app/controllers/import/gitlab_projects_controller.rb b/app/controllers/import/gitlab_projects_controller.rb
index 6b8436d766c..6a3715a4675 100644
--- a/app/controllers/import/gitlab_projects_controller.rb
+++ b/app/controllers/import/gitlab_projects_controller.rb
@@ -48,14 +48,7 @@ class Import::GitlabProjectsController < Import::BaseController
private
def file_is_valid?
- # TODO: remove the condition and the private method after the WH version including
- # https://gitlab.com/gitlab-org/gitlab-workhorse/-/merge_requests/470
- # is released and GITLAB_WORKHORSE_VERSION is updated accordingly.
- if with_workhorse_upload_acceleration?
- return false unless project_params[:file].is_a?(::UploadedFile)
- else
- return false unless project_params[:file] && project_params[:file].respond_to?(:read)
- end
+ return false unless project_params[:file].is_a?(::UploadedFile)
filename = project_params[:file].original_filename
@@ -75,8 +68,4 @@ class Import::GitlabProjectsController < Import::BaseController
def whitelist_query_limiting
Gitlab::QueryLimiting.whitelist('https://gitlab.com/gitlab-org/gitlab-foss/issues/42437')
end
-
- def with_workhorse_upload_acceleration?
- request.headers[Gitlab::Workhorse::INTERNAL_API_REQUEST_HEADER].present?
- end
end