remove more ternaries
This commit is contained in:
@@ -14,7 +14,7 @@ export default async function moveFile(from: string, to: string) {
|
||||
};
|
||||
|
||||
try {
|
||||
s3Client.copyObject(copyParams, async (err: any) => {
|
||||
s3Client.copyObject(copyParams, async (err: unknown) => {
|
||||
if (err) {
|
||||
console.error("Error copying the object:", err);
|
||||
} else {
|
||||
|
||||
@@ -28,10 +28,10 @@ export default async function readFile(filePath: string) {
|
||||
try {
|
||||
let returnObject:
|
||||
| {
|
||||
file: Buffer | string;
|
||||
contentType: ReturnContentTypes;
|
||||
status: number;
|
||||
}
|
||||
file: Buffer | string;
|
||||
contentType: ReturnContentTypes;
|
||||
status: number;
|
||||
}
|
||||
| undefined;
|
||||
|
||||
const headObjectAsync = util.promisify(
|
||||
|
||||
Reference in New Issue
Block a user