Skip to content

Commit

Permalink
refactor: modify commit associatedPRs and relatedIssues label prope…
Browse files Browse the repository at this point in the history
…rty data type.

BREAKING CHANGE: the commit associatedPR and relatedIssues `label` prop is now an array of objects with more properties
  • Loading branch information
babblebey committed Sep 12, 2024
1 parent b8f0c9c commit 718134a
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion lib/success.js
Original file line number Diff line number Diff line change
Expand Up @@ -378,6 +378,8 @@ const baseFields = `
url
name
color
description
isDefault
}
}
milestone {
Expand Down Expand Up @@ -513,7 +515,16 @@ function buildIssuesOrPRsFromResponseNode(responseNodes, type = "ISSUE") {
number: node.number,
title: node.title,
body: node.body,
labels: node.labels?.nodes.map((label) => label.name),
labels: node.labels?.nodes.map((label) => {
return {
id: label.id,
url: label.url,
name: label.name,
color: label.color,
description: label.description,
default: label.isDefault,
};
}),
html_url: node.url,
created_at: node.createdAt,
updated_at: node.updatedAt,
Expand Down

0 comments on commit 718134a

Please sign in to comment.