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/import_export/file_importer.rb')
-rw-r--r--lib/gitlab/import_export/file_importer.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/gitlab/import_export/file_importer.rb b/lib/gitlab/import_export/file_importer.rb
index 37c83e88ef2..7fb7a9f30a0 100644
--- a/lib/gitlab/import_export/file_importer.rb
+++ b/lib/gitlab/import_export/file_importer.rb
@@ -74,17 +74,21 @@ module Gitlab
download(
import_export_upload.remote_import_url,
@archive_file,
- size_limit: ::Import::GitlabProjects::RemoteFileValidator::FILE_SIZE_LIMIT
+ size_limit: file_size_limit
)
else
download_or_copy_upload(
import_export_upload.import_file,
@archive_file,
- size_limit: ::Import::GitlabProjects::RemoteFileValidator::FILE_SIZE_LIMIT
+ size_limit: file_size_limit
)
end
end
+ def file_size_limit
+ Gitlab::CurrentSettings.current_application_settings.max_import_remote_file_size.megabytes
+ end
+
def remove_import_file
FileUtils.rm_rf(@archive_file)
end