Trim space on title #75
@ -6,6 +6,7 @@ package service
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"code.gitea.io/sdk/gitea"
|
||||
@ -92,7 +93,7 @@ func getGiteaTagURL(c *gitea.Client, baseURL, owner, repo, mileName, gitTag, fro
|
||||
func convertToEntry(issue gitea.Issue) Entry {
|
||||
entry := Entry{
|
||||
Index: issue.Index,
|
||||
Title: issue.Title,
|
||||
Title: strings.TrimSpace(issue.Title),
|
||||
}
|
||||
|
||||
labels := make([]Label, len(issue.Labels))
|
||||
|
@ -9,6 +9,7 @@ import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
"os"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/google/go-github/v50/github"
|
||||
@ -58,7 +59,7 @@ func (gh *GitHub) Generate() (string, []Entry, error) {
|
||||
for _, pr := range result.Issues {
|
||||
if pr.IsPullRequest() == isPull {
|
||||
p := Entry{
|
||||
Title: pr.GetTitle(),
|
||||
Title: strings.TrimSpace(pr.GetTitle()),
|
||||
Index: int64(pr.GetNumber()),
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user