FIX: All multisite upload paths should start with /uploads/default/.. (#6707)

This commit is contained in:
Rishabh
2018-12-03 09:34:14 +05:30
committed by Guo Xiang Tan
parent 6121d11187
commit 503ae1829f
3 changed files with 8 additions and 4 deletions

View File

@ -42,7 +42,7 @@ module FileStore
options[:content_disposition] = "attachment; filename=\"#{filename}\"" unless FileHelper.is_supported_image?(filename)
# if this fails, it will throw an exception
path.prepend(File.join(upload_path, "/")) if RailsMultisite::ConnectionManagement.current_db != "default"
path.prepend(File.join(upload_path, "/")) if Rails.configuration.multisite
path = @s3_helper.upload(file, path, options)
# return the upload url