mirror of
https://github.com/discourse/discourse.git
synced 2025-02-16 23:42:44 +08:00
FIX: don't include multisite upload path to source URL if already exist.
This commit is contained in:
parent
a1fc35fdf7
commit
3e456d5c0b
|
@ -71,7 +71,9 @@ class S3Helper
|
|||
if !Rails.configuration.multisite
|
||||
options[:copy_source] = File.join(@s3_bucket_name, source)
|
||||
else
|
||||
if @s3_bucket_folder_path
|
||||
if source.include?(multisite_upload_path) || source.include?(@tombstone_prefix)
|
||||
options[:copy_source] = File.join(@s3_bucket_name, source)
|
||||
elsif @s3_bucket_folder_path
|
||||
folder, filename = begin
|
||||
source.split("/".freeze, 2)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user