Skip to content

Commit

Permalink
fix: remove duplicated code
Browse files Browse the repository at this point in the history
  • Loading branch information
itsyoboieltr committed Jun 11, 2024
1 parent 769dda9 commit f5ab014
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions .github/scripts/shared/labelable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,18 +51,7 @@ export async function addLabelToLabelable(
label,
);

const addLabelsToLabelableMutation = `
mutation AddLabelsToLabelable($labelableId: ID!, $labelIds: [ID!]!) {
addLabelsToLabelable(input: {labelableId: $labelableId, labelIds: $labelIds}) {
clientMutationId
}
}
`;

await octokit.graphql(addLabelsToLabelableMutation, {
labelableId: labelable?.id,
labelIds: [labelId],
});
await addLabelByIdToLabelable(octokit, labelable, labelId);
}

// This function adds label by id to a labelable object (i.e. a pull request or an issue)
Expand Down

0 comments on commit f5ab014

Please sign in to comment.