Skip to content

Commit

Permalink
chore: 简化错误日志
Browse files Browse the repository at this point in the history
  • Loading branch information
bangbang93 committed May 20, 2024
1 parent 97311d0 commit 755d107
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/cluster.ts
Original file line number Diff line number Diff line change
Expand Up @@ -218,8 +218,11 @@ export class Cluster {
} catch (e) {
hasError = true
if (e instanceof HTTPError) {
logger.error({err: e}, `下载文件${file.path}失败: ${e.response.statusCode}, url: ${e.response.url}`)
logger.trace({err: e, options: e.options, redirectUrls: e.response.redirectUrls}, toString(e.response.body))
logger.error(
{redirectUrls: e.response.redirectUrls},
`下载文件${file.path}失败: ${e.response.statusCode}, url: ${e.response.url}`,
)
logger.trace({err: e}, toString(e.response.body))
} else {
logger.error({err: e}, `下载文件${file.path}失败`)
}
Expand Down

0 comments on commit 755d107

Please sign in to comment.