【发布时间】:2021-07-13 04:03:07
【问题描述】:
在开发环境中,错误显示为
{
"type": "https://httpstatuses.com/401",
"title": "Unauthorized",
"status": 401,
"detail": "LOGIN", -- this is where I send detail of the error
"errors": [
{
error-stack
} ...
一旦发布,不仅errors元素丢失,就连detail也丢失了。
{
"type": "https://httpstatuses.com/401",
"title": "Unauthorized",
"status": 401,
"traceId": "|b1bda8d6-44744a1efb1ef714."
}
我怎样才能始终启用detail 元素?
【问题讨论】:
标签: c# asp.net-core error-handling