refactor: 数据库健康检查器内部优先检查 DbContextManager 错误

This commit is contained in:
Argo Zhang 2019-09-02 18:19:02 +08:00
parent 81936ee7f5
commit 019b80ffe8
No known key found for this signature in database
GPG Key ID: 152E398953DDF19F
1 changed files with 1 additions and 1 deletions

View File

@ -99,7 +99,7 @@ namespace Bootstrap.Admin.HealthChecks
if (error != null || DbContextManager.Exception != null)
{
data.Add("Exception", (error ?? DbContextManager.Exception).Message);
data.Add("Exception", (DbContextManager.Exception ?? error).Message);
return Task.FromResult(HealthCheckResult.Unhealthy("Error", error ?? DbContextManager.Exception, data));
}