How get a variable for Node.js in Flutter?
How can I get the ” Jafar ” as a variable in Flutter and set on instead of the ” Jafar” in Node.js?
My code:
const upload = multer({
storage :multerS3({
s3:S3,
bucket:`${config.AWS_BUCKET_NAME}/${'Jafar'}`,
// bucket:config.AWS_BUCKET_NAME,
acl:'public-read',
key :function(req,file,cb){
if(file.fieldname == "singleFile"){
cb(null,"single/"+ file.originalname);
}
if(file.fieldname == "multipliesFiles"){
cb(null,"multipliesFiles/"+ file.originalname);
}
if(file.fieldname != "multipliesFiles" &&file.fieldname != "singleFile" ){
cb(null,"veryPersonal/"+ file.originalname);
}
// cb(null,file.originalname);
}
})
})
Also, I send image.
I tried fined the solution in the internet (YouTube, Github, …) but I didn’t know what to look for in this situation,
Read more here: Source link