Merge pull request #1434 from CyberL1/fix/gh-embeds-new-commits-title-link

This commit is contained in:
Cyber
2025-12-12 22:21:53 +01:00
committed by GitHub

View File

@@ -243,7 +243,7 @@ const parseGitHubWebhook = (req: Request, res: Response, next: NextFunction) =>
url: req.body.sender.html_url,
},
title: `[${req.body.repository.name}:${req.body.ref.slice(11)}] ${req.body.commits.length} new commit${req.body.commits.length > 1 ? "s" : ""}`,
url: req.body.head_commit.url,
url: req.body.commits.length > 1 ? req.body.compare : req.body.head_commit.url,
description: req.body.commits
.slice(0, 5) // Discord only shows 5 first commits
.map(