feat: add convertLabel

This commit is contained in:
Derrick Hammer 2024-02-11 04:56:30 -05:00
parent 4afb7eb108
commit e1d8e122ce
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
1 changed files with 13 additions and 0 deletions

View File

@ -178,6 +178,19 @@ func convertChanges(changes *structs.ChangesPayload) *github.EditChange {
}
}
func convertLabel(label *structs.Label) *github.Label {
if label == nil {
return &github.Label{}
}
return &github.Label{
ID: int64Ptr(label.ID),
Name: stringPtr(label.Name),
Color: stringPtr(label.Color),
Description: stringPtr(label.Description),
URL: stringPtr(label.URL),
}
}
func translatePrAction(action structs.HookIssueAction) string {
translatedAction := ""