gitea/services/webhook
Giteabot 22a93c1cdc
Only provide the commit summary for Discord webhook push events (#32432) (#32447)
Backport #32432 by @kemzeb

Resolves #32371.

#31970 should have just showed the commit summary, but
`strings.SplitN()` was misused such that we did not perform any
splitting at all and just used the message. This was not caught in the
unit test made in that PR since the test commit summary was > 50 (which
truncated away the commit description).

This snapshot resolves this and adds another unit test to ensure that we
only show the commit summary.

Co-authored-by: Kemal Zebari <60799661+kemzeb@users.noreply.github.com>
2024-11-08 09:13:49 +08:00
..
deliver_test.go Fix possible data race on tests (#30093) 2024-03-26 14:08:30 +00:00
deliver.go Support allowed hosts for migrations to work with proxy (#32025) (#32026) 2024-09-11 14:54:19 +08:00
dingtalk_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
dingtalk.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
discord_test.go Only provide the commit summary for Discord webhook push events (#32432) (#32447) 2024-11-08 09:13:49 +08:00
discord.go Only provide the commit summary for Discord webhook push events (#32432) (#32447) 2024-11-08 09:13:49 +08:00
feishu_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
feishu.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
general_test.go Only provide the commit summary for Discord webhook push events (#32432) (#32447) 2024-11-08 09:13:49 +08:00
general.go Fix package webhook (#27839) 2023-10-31 04:43:38 +00:00
main_test.go make writing main test easier (#27270) 2023-09-28 01:38:53 +00:00
matrix_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
matrix.go Enable more revive linter rules (#30608) 2024-04-22 11:48:42 +00:00
msteams_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
msteams.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
notifier.go Fix missed doer (#30231) 2024-04-08 21:26:41 +00:00
packagist_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
packagist.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
payloader.go Fix broken webhooks (#29690) 2024-03-10 01:32:48 +00:00
slack_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
slack.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
telegram_test.go Use old behavior for telegram webhook (#31588) 2024-07-09 11:23:33 +08:00
telegram.go Use old behavior for telegram webhook (#31588) 2024-07-09 11:23:33 +08:00
webhook_test.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
webhook.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00
wechatwork.go Store webhook event in database (#29145) 2024-03-07 23:18:38 +01:00