mirror of
https://github.com/spacebarchat/server.git
synced 2026-08-05 19:09:29 +00:00
Merge pull request #1422 from CyberL1/fix/github-embed-push-show-only-the-first-line
This commit is contained in:
@@ -246,7 +246,7 @@ const parseGitHubWebhook = (req: Request, res: Response, next: NextFunction) =>
|
||||
.slice(0, 5) // Discord only shows 5 first commits
|
||||
.map(
|
||||
(c: { id: string; url: string; message: string; author: { username: string } }) =>
|
||||
`[\`${c.id.slice(0, 7)}\`](${c.url}) ${c.message.length > 46 ? `${c.message.slice(0, 47)}...` : c.message} - ${c.author.username}`,
|
||||
`[\`${c.id.slice(0, 7)}\`](${c.url}) ${c.message.split("\n")[0].length > 46 ? `${c.message.slice(0, 47)}...` : c.message.split("\n")[0]} - ${c.author.username}`,
|
||||
)
|
||||
.join("\n"),
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user