mirror of
https://github.com/go-gitea/gitea.git
synced 2025-10-27 00:23:41 +09:00
Avoid sending "0 new commits" webhook
Signed-off-by: Till Faelligen <tfaelligen@gmail.com>
This commit is contained in:
@@ -145,6 +145,10 @@ func getMatrixReleasePayload(p *api.ReleasePayload, matrix *MatrixMeta) (*Matrix
|
||||
}
|
||||
|
||||
func getMatrixPushPayload(p *api.PushPayload, matrix *MatrixMeta) (*MatrixPayloadUnsafe, error) {
|
||||
if len(p.Commits) == 0 {
|
||||
return nil, fmt.Errorf("no commits in payload")
|
||||
}
|
||||
|
||||
var commitDesc string
|
||||
|
||||
if len(p.Commits) == 1 {
|
||||
|
||||
Reference in New Issue
Block a user