log total files to delete
This commit is contained in:
parent
5f106cd378
commit
ebb7729fd0
1 changed files with 5 additions and 1 deletions
|
@ -49,14 +49,18 @@ objectsResponse.on('data', function(objects) {
|
|||
});
|
||||
});
|
||||
|
||||
const filesToDelete = [];
|
||||
objectsResponse.on('end', () => {
|
||||
console.log(uploadedFiles.length);
|
||||
uploadedFiles.forEach(fileKey => {
|
||||
if (s3Files.indexOf(fileKey) === -1) {
|
||||
//delete file
|
||||
console.log("would delete file: ", fileKey);
|
||||
filesToDelete.push(fileKey);
|
||||
// console.log("would delete file: ", fileKey);
|
||||
}
|
||||
});
|
||||
console.log("To delete: ", filesToDelete.length);
|
||||
console.log("Total S3 files: ", uploadedFiles.length);
|
||||
});
|
||||
|
||||
// let projectsNotToUpdate;
|
||||
|
|
Loading…
Reference in a new issue