Commit 76c67b5d authored by xzj's avatar xzj

修复异常

parent 565bf0f0
......@@ -114,7 +114,7 @@ module.exports = function (options) {
return new Promise(function (resolve, reject) {
let r = ctx.req.pipe(request(option, function (err, response) {
if (option.time && options.logger) {
options.logger.info(option.url || option.uri, JSON.stringify(response.timings))
options.logger.info(option.url || option.uri, JSON.stringify(response && response.timings || ''))
}
}))
r.on('error', function (err) {
......
{
"name": "request-proxy",
"version": "1.0.3",
"version": "1.0.4",
"description": "",
"main": "index.js",
"scripts": {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment