非同期処理修正

This commit is contained in:
ろむねこ 2024-06-17 11:53:09 +09:00
parent e16b8ce14e
commit 23029c7eb5
Signed by: Fujimatsu
GPG Key ID: FA1F39A1BA37D168

View File

@ -7,12 +7,12 @@ router.get('/ping', (req: Request, res: Response) => {
res.send('pong');
});
router.get('/' , (req: Request, res: Response) => {
router.get('/' , async (req: Request, res: Response) => {
res.json({
"commitHash": getCommitHash(),
"branchName": getBranchName(),
"commitDate": getCommitDate(),
"commitMessage": getCommitMessage()
"commitHash": await getCommitHash(),
"branchName": await getBranchName(),
"commitDate": await getCommitDate(),
"commitMessage": await getCommitMessage()
});
});