diff options
author | John Olheiser <42128690+jolheiser@users.noreply.github.com> | 2020-01-04 16:20:15 -0600 |
---|---|---|
committer | zeripath <art27@cantab.net> | 2020-01-04 22:20:15 +0000 |
commit | fb3a6aba7de2a22e102636c010b7c1faf740f1d7 (patch) | |
tree | 86a798b39eba88bd7d9c42cea302ab9193400e6d /modules/webhook/telegram.go | |
parent | 07439d8059f80972aaf6b49dd3f3ff699d775b01 (diff) | |
download | gitea-fb3a6aba7de2a22e102636c010b7c1faf740f1d7.tar.gz gitea-fb3a6aba7de2a22e102636c010b7c1faf740f1d7.zip |
Only show sender if it makes sense (#9601)
Signed-off-by: jolheiser <john.olheiser@gmail.com>
Diffstat (limited to 'modules/webhook/telegram.go')
-rw-r--r-- | modules/webhook/telegram.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/webhook/telegram.go b/modules/webhook/telegram.go index a98d47d55c..42adb40be2 100644 --- a/modules/webhook/telegram.go +++ b/modules/webhook/telegram.go @@ -125,7 +125,7 @@ func getTelegramPushPayload(p *api.PushPayload) (*TelegramPayload, error) { } func getTelegramIssuesPayload(p *api.IssuePayload) (*TelegramPayload, error) { - text, _, attachmentText, _ := getIssuesPayloadInfo(p, htmlLinkFormatter) + text, _, attachmentText, _ := getIssuesPayloadInfo(p, htmlLinkFormatter, true) return &TelegramPayload{ Message: text + "\n\n" + attachmentText, @@ -133,7 +133,7 @@ func getTelegramIssuesPayload(p *api.IssuePayload) (*TelegramPayload, error) { } func getTelegramIssueCommentPayload(p *api.IssueCommentPayload) (*TelegramPayload, error) { - text, _, _ := getIssueCommentPayloadInfo(p, htmlLinkFormatter) + text, _, _ := getIssueCommentPayloadInfo(p, htmlLinkFormatter, true) return &TelegramPayload{ Message: text + "\n" + p.Comment.Body, @@ -141,7 +141,7 @@ func getTelegramIssueCommentPayload(p *api.IssueCommentPayload) (*TelegramPayloa } func getTelegramPullRequestPayload(p *api.PullRequestPayload) (*TelegramPayload, error) { - text, _, attachmentText, _ := getPullRequestPayloadInfo(p, htmlLinkFormatter) + text, _, attachmentText, _ := getPullRequestPayloadInfo(p, htmlLinkFormatter, true) return &TelegramPayload{ Message: text + "\n" + attachmentText, @@ -166,7 +166,7 @@ func getTelegramRepositoryPayload(p *api.RepositoryPayload) (*TelegramPayload, e } func getTelegramReleasePayload(p *api.ReleasePayload) (*TelegramPayload, error) { - text, _ := getReleasePayloadInfo(p, htmlLinkFormatter) + text, _ := getReleasePayloadInfo(p, htmlLinkFormatter, true) return &TelegramPayload{ Message: text + "\n", |