Skip to content

Commit

Permalink
fix: update where leading / is added for getUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
Jordan-Nelson committed Mar 26, 2024
1 parent dd72447 commit c3376b7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ class StorageS3Service {
'${_s3PluginConfig.bucket}.${_getS3EndpointHost(region: _s3PluginConfig.region)}';
if (_defaultS3ClientConfig.usePathStyle) {
host = host.replaceFirst('${_s3PluginConfig.bucket}.', '');
resolvedPath = '/${_s3PluginConfig.bucket}/$resolvedPath';
resolvedPath = '${_s3PluginConfig.bucket}/$resolvedPath';
} else if (s3PluginOptions.useAccelerateEndpoint) {
// https: //docs.aws.amazon.com/AmazonS3/latest/userguide/transfer-acceleration-getting-started.html
host = host
Expand All @@ -271,7 +271,7 @@ class StorageS3Service {
final urlRequest = AWSHttpRequest.raw(
method: AWSHttpMethod.get,
host: host,
path: resolvedPath,
path: '/$resolvedPath',
);

return S3GetUrlResult(
Expand Down

0 comments on commit c3376b7

Please sign in to comment.