diff --git a/BACKEND/app/controllers/healcheck_controller.ts b/BACKEND/app/controllers/healcheck_controller.ts index cf315ff..9ff71d7 100644 --- a/BACKEND/app/controllers/healcheck_controller.ts +++ b/BACKEND/app/controllers/healcheck_controller.ts @@ -70,7 +70,7 @@ export default class HealCheckController { { name: 'wiki', status: resWiki.status < 400 ? true : false, - message: resWiki.data?.message || 'Checking api wiki success', + message: resWiki.status < 400 ? 'Checking api wiki success' : 'Checking api wiki fail', }, { ...dataCheckNote, @@ -89,12 +89,16 @@ export default class HealCheckController { { name: 'wiki', status: error?.response?.config?.url?.includes(linkWiki) ? false : true, - message: error?.message || 'Checking api wiki fail', + message: error?.response?.config?.url?.includes(linkWiki) + ? 'Checking api wiki fail' + : 'Checking api wiki success', }, { name: 'update-note-sn', status: error?.response?.config?.url?.includes(remoteUrl) ? false : true, - message: error?.message || 'Checking api update note SN fail', + message: error?.response?.config?.url?.includes(remoteUrl) + ? 'Checking api update note SN fail' + : 'Checking api update note SN success', }, ], }