mirror of
https://github.com/strapi/strapi.git
synced 2025-12-26 22:54:31 +00:00
Merge pull request #3426 from strapi/tech/handle-health-bad-status-code
Add status code handler to health checks
This commit is contained in:
commit
9d8025ed27
@ -91,7 +91,10 @@ function serverRestartWatcher(response) {
|
||||
'Keep-Alive': false,
|
||||
},
|
||||
})
|
||||
.then(() => {
|
||||
.then(res => {
|
||||
if (res.status >= 400) {
|
||||
throw new Error('not available');
|
||||
}
|
||||
// Hide the global OverlayBlocker
|
||||
strapi.unlockApp();
|
||||
resolve(response);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user