mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 06:04:11 +08:00
FIX: Redirecting to download backup from S3 could fail (#20171)
Follow-up to 008b700a3f
This commit is contained in:
parent
4fee7f43ba
commit
7482b0f703
|
@ -84,7 +84,7 @@ class Admin::BackupsController < Admin::AdminController
|
||||||
StaffActionLogger.new(current_user).log_backup_download(backup)
|
StaffActionLogger.new(current_user).log_backup_download(backup)
|
||||||
|
|
||||||
if store.remote?
|
if store.remote?
|
||||||
redirect_to backup.source
|
redirect_to backup.source, allow_other_host: true
|
||||||
else
|
else
|
||||||
headers["Content-Length"] = File.size(backup.source).to_s
|
headers["Content-Length"] = File.size(backup.source).to_s
|
||||||
send_file backup.source
|
send_file backup.source
|
||||||
|
|
Loading…
Reference in New Issue
Block a user