It is possible in an s3s service to trigger a 307 redirect response from within an S3 trait method by returning Err(s3_error!(TemporaryRedirect)) but I cannot find a way to set the Location header in the response, and without this the redirect is not particularly useful. Is there currently any way to add the location header at present?
If not, rather than implement something specific to redirects, perhaps it would be easiest to simply add a header map to the S3Error type that can be handled much the same as in S3Response?
It is possible in an s3s service to trigger a 307 redirect response from within an S3 trait method by returning
Err(s3_error!(TemporaryRedirect))
but I cannot find a way to set theLocation
header in the response, and without this the redirect is not particularly useful. Is there currently any way to add the location header at present?If not, rather than implement something specific to redirects, perhaps it would be easiest to simply add a header map to the
S3Error
type that can be handled much the same as inS3Response
?