Skip to content

Commit f7753cc

Browse files
authored
fix: partial s3 upload ignoring subdirectory (#910, #909)
1 parent 2ad10e9 commit f7753cc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/lib/datasource/S3.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ export class S3Datasource extends Datasource {
6464
this.ensureReadWriteAccess();
6565
}
6666

67-
private key(path: string): string {
67+
public key(path: string): string {
6868
if (this.options.subdirectory) {
6969
return this.options.subdirectory.endsWith('/')
7070
? this.options.subdirectory + path

src/offload/partial.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ async function main() {
152152
client: s3datasource.client,
153153
params: {
154154
Bucket: s3datasource.options.bucket,
155-
Key: file.filename,
155+
Key: s3datasource.key(file.filename),
156156
Body: bodyStream,
157157
},
158158
partSize: bytes(config.chunks.size),

0 commit comments

Comments
 (0)