Fix: It didnt show messasge when commit

This commit is contained in:
austinsuyoyo 2021-02-11 14:32:01 +08:00
parent 4b9a9b476a
commit 5e5be68f67

View File

@ -93,18 +93,12 @@ const giteaEvents = {
const repo = request.content.repository;
const branch = request.content.ref.split('/').pop();
if (commits.length > 1) {
var title = "Show all commits";
} else {
var title = ""
}
const attachment = {
collapsed: true,
title: title,
title: "Show " + commits.length + " commit",
fields: []
};
for (var i = 0; i < commits.length; i++) {
var commit = commits[i];
var shortID = commit.id.substring(0, 7);