fix: add missing convertChanges

This commit is contained in:
Derrick Hammer 2024-02-11 04:47:58 -05:00
parent d97dd79e59
commit 0093a15645
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
1 changed files with 19 additions and 0 deletions

View File

@ -147,6 +147,25 @@ func convertPullRequest(request *structs.PullRequest) *github.PullRequest {
return pr
}
func convertChanges(changes *structs.ChangesPayload) *github.EditChange {
if changes == nil {
return nil
}
return &github.EditChange{
Title: &github.EditTitle{
From: stringPtr(changes.Title.From),
},
Body: &github.EditBody{
From: stringPtr(changes.Body.From),
},
Base: &github.EditBase{
Ref: &github.EditRef{
From: stringPtr(changes.Ref.From),
},
},
}
}
func translatePrAction(action structs.HookIssueAction) string {
translatedAction := ""