From 05683f313b40e1c37fbfbb04bd4d0e368dc5b39a Mon Sep 17 00:00:00 2001 From: Kamil Trzcinski Date: Mon, 12 Jun 2017 23:42:11 +0200 Subject: Fix filename method of GitlabUploader to return always real filename --- app/uploaders/gitlab_uploader.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'app/uploaders') diff --git a/app/uploaders/gitlab_uploader.rb b/app/uploaders/gitlab_uploader.rb index 136ec6cc6af..0da7a025591 100644 --- a/app/uploaders/gitlab_uploader.rb +++ b/app/uploaders/gitlab_uploader.rb @@ -61,6 +61,10 @@ class GitlabUploader < CarrierWave::Uploader::Base CarrierWave.tmp_path end + def filename + super || file&.filename + end + private # To prevent files from moving across filesystems, override the default -- cgit v1.2.1