🚨 Fix linter in s3 storage connector

This commit is contained in:
Eric Doughty-Papassideris
2024-03-20 23:29:42 +01:00
committed by Anton Shepilov
parent 1ffb2eb3ea
commit 987da01692
@@ -38,14 +38,18 @@ export default class S3ConnectorService implements StorageConnectorAPI {
.on("data", function (chunk) { .on("data", function (chunk) {
totalSize += chunk.length; totalSize += chunk.length;
}) })
.on('end', () => { // TODO: this could be bad practice as it puts the stream in flow mode before putObject gets to it .on("end", () => {
// TODO: this could be bad practice as it puts the stream in flow mode before putObject gets to it
didCompleteCalculateSize = true; didCompleteCalculateSize = true;
doResolve(); doResolve();
}); });
this.client.putObject(this.minioConfiguration.bucket, path, stream).then(_x => { this.client
didCompletePutObject = true; .putObject(this.minioConfiguration.bucket, path, stream)
doResolve(); .then(_x => {
}).catch(reject); didCompletePutObject = true;
doResolve();
})
.catch(reject);
}); });
} }