createReadStream

This commit is contained in:
unknown 2023-06-04 12:43:19 +02:00
parent 089332dfaa
commit 85c284ea94
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@ async function uploadVideo(video) {
endpoint: 'https://gateway.storjshare.io' endpoint: 'https://gateway.storjshare.io'
}) })
const videoFile = fs.readFileSync(video) const videoFile = fs.createReadStream(video)
await s3.upload({ await s3.upload({
Bucket: 'video', Bucket: 'video',
Key: video.split('/')[2], Key: video.split('/')[2],