lean-s3 0.8.0 → 0.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +2 -2
- package/dist/index.js +3 -4
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -634,10 +634,10 @@ declare class S3File {
|
|
|
634
634
|
write(data: ByteSource, options?: S3FileWriteOptions): Promise<void>;
|
|
635
635
|
/**
|
|
636
636
|
* Copies this file to a new destination.
|
|
637
|
-
* @param destination The destination path
|
|
637
|
+
* @param destination The destination path.
|
|
638
638
|
* @param options Options for the copy operation.
|
|
639
639
|
*/
|
|
640
|
-
copyTo(destination: string
|
|
640
|
+
copyTo(destination: string, options?: CopyObjectOptions): Promise<void>;
|
|
641
641
|
}
|
|
642
642
|
interface S3FileDeleteOptions extends OverridableS3ClientOptions {
|
|
643
643
|
/** Signal to abort the request. */
|
package/dist/index.js
CHANGED
|
@@ -598,7 +598,7 @@ var S3Client = class {
|
|
|
598
598
|
const destinationBucket = options.destinationBucket ? ensureValidBucketName(options.destinationBucket) : this.#options.bucket;
|
|
599
599
|
const normalizedSourceKey = normalizePath(ensureValidPath(sourceKey));
|
|
600
600
|
const copySource = encodeURIComponent(
|
|
601
|
-
|
|
601
|
+
`${sourceBucket}/${normalizedSourceKey}`
|
|
602
602
|
);
|
|
603
603
|
const response = await this[kSignedRequest](
|
|
604
604
|
this.#options.region,
|
|
@@ -1775,12 +1775,11 @@ var S3File = class _S3File {
|
|
|
1775
1775
|
}
|
|
1776
1776
|
/**
|
|
1777
1777
|
* Copies this file to a new destination.
|
|
1778
|
-
* @param destination The destination path
|
|
1778
|
+
* @param destination The destination path.
|
|
1779
1779
|
* @param options Options for the copy operation.
|
|
1780
1780
|
*/
|
|
1781
1781
|
async copyTo(destination, options = {}) {
|
|
1782
|
-
|
|
1783
|
-
await this.#client.copyObject(this.#path, destinationKey, options);
|
|
1782
|
+
await this.#client.copyObject(this.#path, destination, options);
|
|
1784
1783
|
}
|
|
1785
1784
|
};
|
|
1786
1785
|
export {
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "lean-s3",
|
|
3
3
|
"author": "Niklas Mollenhauer",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"version": "0.8.
|
|
5
|
+
"version": "0.8.3",
|
|
6
6
|
"description": "A server-side S3 API for the regular user.",
|
|
7
7
|
"keywords": [
|
|
8
8
|
"s3",
|
|
@@ -51,8 +51,8 @@
|
|
|
51
51
|
"@testcontainers/localstack": "^11.5.1",
|
|
52
52
|
"@testcontainers/minio": "^11.5.1",
|
|
53
53
|
"@types/node": "^24.3.0",
|
|
54
|
-
"@typescript/native-preview": "^7.0.0-dev.
|
|
55
|
-
"expect": "^30.
|
|
54
|
+
"@typescript/native-preview": "^7.0.0-dev.20250828.1",
|
|
55
|
+
"expect": "^30.1.1",
|
|
56
56
|
"lefthook": "^1.12.3",
|
|
57
57
|
"testcontainers": "^11.5.1",
|
|
58
58
|
"tsup": "^8.5.0",
|