fix: change help download from .docx to .pdf

This commit is contained in:
root
2026-07-16 10:01:47 +00:00
parent 6fa8c58179
commit 5353fb2b4e
3 changed files with 9 additions and 9 deletions

View File

@@ -473,11 +473,11 @@ router.get('/master-template', async (req, res) => {
}
});
// GET /api/carbone/help-docx - Download tags reference as .docx
router.get('/help-docx', (req, res) => {
const helpPath = path.join(TEMPLATES_DIR, 'HELP_TAGS_REFERENCE.docx');
// GET /api/carbone/help-pdf - Download tags reference as .pdf
router.get('/help-pdf', (req, res) => {
const helpPath = path.join(TEMPLATES_DIR, 'HELP_TAGS_REFERENCE.pdf');
if (fs.existsSync(helpPath)) {
res.download(helpPath, 'Carbone_Tags_Reference.docx');
res.download(helpPath, 'Carbone_Tags_Reference.pdf');
} else {
res.status(404).json({ error: 'Help file not found' });
}