Merge pull request #7349 from srna/patch-1
Attachment URL with non-/ relative root
This commit is contained in:
commit
b37b71d887
1 changed files with 4 additions and 0 deletions
|
@ -26,6 +26,10 @@ class AttachmentUploader < CarrierWave::Uploader::Base
|
|||
Gitlab.config.gitlab.relative_url_root + "/files/#{model.class.to_s.underscore}/#{model.id}/#{file.filename}"
|
||||
end
|
||||
|
||||
def url
|
||||
Gitlab.config.gitlab.relative_url_root + super unless super.nil?
|
||||
end
|
||||
|
||||
def file_storage?
|
||||
self.class.storage == CarrierWave::Storage::File
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue