We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how can i use node-restful with connect-multiparty ?
The text was updated successfully, but these errors were encountered:
routes.js
` const express = require('express'); const swaggerUi = require('swagger-ui-express'); const swaggerDocument = require('../../swagger.json');
module.exports = (server) => {
const routerAPI = express.Router(); server.use('/api', routerAPI); server.use('/api-docs', swaggerUi.serve, swaggerUi.setup(swaggerDocument)); const User = require('../api/user/userService'); User.register(routerAPI, '/users'); const AnexoService = require('../api/anexo/anexoService'); routerAPI.post('/upload', AnexoService.upload);
} `
anexoService.js
` const path = require('path'); const multiparty = require('connect-multiparty');
const pathDir = path.join(__dirname, '../upload');
const multipartyMiddleware = multiparty({ uploadDir: pathDir})
const upload = (multipartyMiddleware, function(req, res, next) { console.log(req); // undefined
// var file = req.files.file; // undefined // console.log(file.name); // console.log(file.type);
});
module.exports = { upload }; `
Sorry, something went wrong.
No branches or pull requests
how can i use node-restful with connect-multiparty ?
The text was updated successfully, but these errors were encountered: