mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
Revert "Revert "FIX: GlobalPath#upload_cdn_path when S3 bucket has a folder (#6523)""
This reverts commit 322b27b6dcba0ec37323b3fef64fec6075c68fe6. Oops rushed on the revert here... should be good
This commit is contained in:
@ -9,7 +9,7 @@ module GlobalPath
|
||||
|
||||
def upload_cdn_path(p)
|
||||
if SiteSetting.Upload.s3_cdn_url.present?
|
||||
p = p.sub(Discourse.store.absolute_base_url, SiteSetting.Upload.s3_cdn_url)
|
||||
p = Discourse.store.cdn_url(p)
|
||||
end
|
||||
p =~ /^http/ ? p : cdn_path(p)
|
||||
end
|
||||
|
Reference in New Issue
Block a user