diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-29 21:08:47 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-29 21:08:47 +0300 |
commit | 6b9d3a4e8351e662c4586b24bb152de78ae9e3bf (patch) | |
tree | 883e9db60c047c54418fc1d2b1c5517f97e0f185 /lib/api/helpers.rb | |
parent | 23288f62da73fb0e30d8e7ce306665e8fda1b932 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/api/helpers.rb')
-rw-r--r-- | lib/api/helpers.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/api/helpers.rb b/lib/api/helpers.rb index aa6071e6099..688b1cc6f17 100644 --- a/lib/api/helpers.rb +++ b/lib/api/helpers.rb @@ -434,7 +434,7 @@ module API def present_disk_file!(path, filename, content_type = 'application/octet-stream') filename ||= File.basename(path) - header['Content-Disposition'] = ::Gitlab::ContentDisposition.format(disposition: 'attachment', filename: filename) + header['Content-Disposition'] = ActionDispatch::Http::ContentDisposition.format(disposition: 'attachment', filename: filename) header['Content-Transfer-Encoding'] = 'binary' content_type content_type @@ -542,7 +542,7 @@ module API def send_git_blob(repository, blob) env['api.format'] = :txt content_type 'text/plain' - header['Content-Disposition'] = ::Gitlab::ContentDisposition.format(disposition: 'inline', filename: blob.name) + header['Content-Disposition'] = ActionDispatch::Http::ContentDisposition.format(disposition: 'inline', filename: blob.name) # Let Workhorse examine the content and determine the better content disposition header[Gitlab::Workhorse::DETECT_HEADER] = "true" |