mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-31 21:28:11 +09:00 
			
		
		
		
	Fix package webhook (#27839)
Fix #23742 --------- Co-authored-by: KN4CK3R <admin@oldschoolhack.me>
This commit is contained in:
		| @@ -256,6 +256,12 @@ func (d *DiscordPayload) Release(p *api.ReleasePayload) (api.Payloader, error) { | ||||
| 	return d.createPayload(p.Sender, text, p.Release.Note, p.Release.HTMLURL, color), nil | ||||
| } | ||||
|  | ||||
| func (d *DiscordPayload) Package(p *api.PackagePayload) (api.Payloader, error) { | ||||
| 	text, color := getPackagePayloadInfo(p, noneLinkFormatter, false) | ||||
|  | ||||
| 	return d.createPayload(p.Sender, text, "", p.Package.HTMLURL, color), nil | ||||
| } | ||||
|  | ||||
| // GetDiscordPayload converts a discord webhook into a DiscordPayload | ||||
| func GetDiscordPayload(p api.Payloader, event webhook_module.HookEventType, meta string) (api.Payloader, error) { | ||||
| 	s := new(DiscordPayload) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user