Commit be535103 authored by Andy Wilkinson's avatar Andy Wilkinson

Merge pull request #9832 from Johnny Lim

* gh-9832:
  Use currentHealth consistently in getHealth()
parents 39b4ecdf d18e452f
......@@ -165,7 +165,7 @@ public class HealthMvcEndpoint extends AbstractEndpointMvcAdapter<HealthEndpoint
private Health getHealth(HttpServletRequest request, Principal principal) {
Health currentHealth = getCurrentHealth();
if (exposeHealthDetails(request, principal)) {
return this.cachedHealth.health;
return currentHealth;
}
return Health.status(currentHealth.getStatus()).build();
}
......
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