Тестовый коммит после удаления husky

This commit is contained in:
2025-03-05 01:02:09 +03:00
parent 97ca5e4b64
commit 3157ad0cd9
118 changed files with 8177 additions and 8530 deletions

View File

@@ -6,11 +6,11 @@ router.get('/', async (req, res) => {
try {
// Проверка соединения с базой данных
const dbResult = await db.query('SELECT NOW()');
// Проверка состояния сервера
const memoryUsage = process.memoryUsage();
const uptime = process.uptime();
res.json({
status: 'ok',
timestamp: new Date(),
@@ -18,19 +18,19 @@ router.get('/', async (req, res) => {
memory: {
rss: Math.round(memoryUsage.rss / 1024 / 1024) + 'MB',
heapTotal: Math.round(memoryUsage.heapTotal / 1024 / 1024) + 'MB',
heapUsed: Math.round(memoryUsage.heapUsed / 1024 / 1024) + 'MB'
heapUsed: Math.round(memoryUsage.heapUsed / 1024 / 1024) + 'MB',
},
database: {
connected: true,
timestamp: dbResult.rows[0].now
}
timestamp: dbResult.rows[0].now,
},
});
} catch (error) {
res.status(500).json({
status: 'error',
error: error.message
error: error.message,
});
}
});
module.exports = router;
module.exports = router;