text: const multer = require('multer');
  
  const excelFilter = (req, file, cb) => {
    if (
      file.mimetype.includes('excel')
      || file.mimetype.includes('spreadsheetml')
    ) {
      cb(null, true);
    } else {
      cb('Please upload only excel file.', false);
    }
  };
  
  const storage = multer.diskStorage({
    destination: (req, file, cb) => {
      cb(null, `${__dirname}../../../resources/static/assets/uploads/`);
    },
    filename: (req, file, cb) => {
      console.log(file.originalname);
      cb(null, `${file.originalname}`);
    },
  });
  
  const uploadFile = multer({ storage, fileFilter: excelFilter });
  module.exports = uploadFile;
  