Skip to content

Commit 029e5f4

Browse files
committed
chore: eslint --fix lib/**/src/**/*.ts
1 parent 75ab3cb commit 029e5f4

File tree

8 files changed

+23
-18
lines changed

8 files changed

+23
-18
lines changed

lib/lib-dynamodb/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
export * from "./commands/BatchExecuteStatementCommand";
22
export * from "./commands/BatchGetCommand";
33
export * from "./commands/BatchWriteCommand";
4+
export * from "./DynamoDBDocumentClient";
45
export * from "./commands/DeleteCommand";
6+
export * from "./DynamoDBDocument";
57
export * from "./commands/ExecuteStatementCommand";
68
export * from "./commands/ExecuteTransactionCommand";
79
export * from "./commands/GetCommand";
@@ -11,5 +13,3 @@ export * from "./commands/ScanCommand";
1113
export * from "./commands/TransactGetCommand";
1214
export * from "./commands/TransactWriteCommand";
1315
export * from "./commands/UpdateCommand";
14-
export * from "./DynamoDBDocumentClient";
15-
export * from "./DynamoDBDocument";

lib/lib-storage/src/Upload.spec.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,10 @@ jest.mock("@aws-sdk/client-s3", () => ({
3737
}));
3838

3939
import { S3 } from "@aws-sdk/client-s3";
40-
import { Upload, Progress } from "./index";
4140
import { Readable } from "stream";
4241

42+
import { Progress, Upload } from "./index";
43+
4344
const DEFAULT_PART_SIZE = 1024 * 1024 * 5;
4445

4546
describe(Upload.name, () => {
@@ -459,7 +460,7 @@ describe(Upload.name, () => {
459460
client: new S3({}),
460461
});
461462

462-
let received = [];
463+
const received = [];
463464
upload.on("httpUploadProgress", (progress: Progress) => {
464465
received.push(progress);
465466
});
@@ -496,7 +497,7 @@ describe(Upload.name, () => {
496497
client: new S3({}),
497498
});
498499

499-
let received = [];
500+
const received = [];
500501
upload.on("httpUploadProgress", (progress: Progress) => {
501502
received.push(progress);
502503
});
@@ -527,7 +528,7 @@ describe(Upload.name, () => {
527528
client: new S3({}),
528529
});
529530

530-
let received = [];
531+
const received = [];
531532
upload.on("httpUploadProgress", (progress: Progress) => {
532533
received.push(progress);
533534
});
@@ -551,7 +552,7 @@ describe(Upload.name, () => {
551552
client: new S3({}),
552553
});
553554

554-
let received = [];
555+
const received = [];
555556
upload.on("httpUploadProgress", (progress: Progress) => {
556557
received.push(progress);
557558
});

lib/lib-storage/src/Upload.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { AbortController, AbortSignal } from "@aws-sdk/abort-controller";
12
import {
23
CompletedPart,
34
CompleteMultipartUploadCommand,
@@ -12,10 +13,10 @@ import {
1213
UploadPartCommand,
1314
} from "@aws-sdk/client-s3";
1415
import { EventEmitter } from "events";
15-
import { BodyDataTypes, Options, Progress, ServiceClients } from "./types";
16-
import { getChunk } from "./chunker";
16+
1717
import { byteLength } from "./bytelength";
18-
import { AbortController, AbortSignal } from "@aws-sdk/abort-controller";
18+
import { getChunk } from "./chunker";
19+
import { BodyDataTypes, Options, Progress, ServiceClients } from "./types";
1920

2021
export interface RawDataPart {
2122
partNumber: number;
@@ -53,7 +54,7 @@ export class Upload extends EventEmitter {
5354
private uploadId?: string;
5455
uploadEvent?: string;
5556

56-
private isMultiPart: boolean = true;
57+
private isMultiPart = true;
5758
private putResponse?: PutObjectCommandOutput;
5859

5960
constructor(options: Options) {

lib/lib-storage/src/chunker.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
import { Readable } from "stream";
21
import { Buffer } from "buffer";
2+
import { Readable } from "stream";
33

4-
import { BodyDataTypes } from "./types";
54
import { getChunkBuffer } from "./chunks/getChunkBuffer";
65
import { getChunkStream } from "./chunks/getChunkStream";
7-
import { getDataReadableStream } from "./chunks/getDataReadableStream";
86
import { getDataReadable } from "./chunks/getDataReadable";
7+
import { getDataReadableStream } from "./chunks/getDataReadableStream";
8+
import { BodyDataTypes } from "./types";
99

1010
export const getChunk = (data: BodyDataTypes, partSize: number) => {
1111
if (data instanceof Buffer) {

lib/lib-storage/src/chunks/getChunkStream.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
import { RawDataPart } from "../Upload";
21
import { Buffer } from "buffer";
32

3+
import { RawDataPart } from "../Upload";
4+
45
interface Buffers {
56
chunks: Buffer[];
67
length: number;

lib/lib-storage/src/chunks/getDataReadable.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
import { Readable } from "stream";
2+
23
import { byteLength } from "../bytelength";
4+
import { RawDataPart as DataPart } from "../Upload";
35
import { getChunkStream as chunkFromReadable } from "./getChunkStream";
46
import { getDataReadable } from "./getDataReadable";
5-
import { RawDataPart as DataPart } from "../Upload";
67

78
const fs = require("fs");
89

lib/lib-storage/src/chunks/getDataReadable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { Readable } from "stream";
21
import { Buffer } from "buffer";
2+
import { Readable } from "stream";
33

44
export async function* getDataReadable(data: Readable): AsyncGenerator<Buffer> {
55
for await (const chunk of data) {

lib/lib-storage/src/runtimeConfig.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
import { ClientSharedValues } from "./runtimeConfig.shared";
21
import { lstatSync } from "fs";
32

3+
import { ClientSharedValues } from "./runtimeConfig.shared";
4+
45
/**
56
* @internal
67
*/

0 commit comments

Comments
 (0)