Upload error with Multer Cloudinary
dungphanxuan opened this issue · 1 comments
dungphanxuan commented
I integrate multer with cloudinary https://github.com/affanshahid/multer-storage-cloudinary. When i upload from another site, sometime throw error.
I'm not pro Nodejs. So can you suggest to fix it.
UNHANDLED_REJECTION: { error:
{ Error: connect ETIMEDOUT 52.1.216.155:443
at Object._errnoException (util.js:992:11)
at _exceptionWithHostPort (util.js:1014:20)
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1186:14)
code: 'ETIMEDOUT',
errno: 'ETIMEDOUT',
syscall: 'connect',
address: '52.1.216.155',
port: 443 } }
UNHANDLED_EXCEPTION: TypeError: Cannot read property 'toString' of undefined
at process.once.err (C:\My Web Sites\DropIt-Clouddinary\app.js:330:52)
at Object.onceWrapper (events.js:317:30)
at emitTwo (events.js:126:13)
at process.emit (events.js:214:7)
at C:\My Web Sites\DropIt-Clouddinary\node_modules\q\q.js:1079:25
at runSingle (C:\My Web Sites\DropIt-Clouddinary\node_modules\q\q.js:137:1
at flush (C:\My Web Sites\DropIt-Clouddinary\node_modules\q\q.js:130:13)
at _combinedTickCallback (internal/process/next_tick.js:131:7)
at process._tickCallback (internal/process/next_tick.js:180:9)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! dropit@1.0.0 start: `node app.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the dropit@1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional lging output above.
dungphanxuan commented
How can i await when upload success then response data?
https://github.com/ThalKod/DropIt/blob/master/app.js#L108