fix: getIssue

This commit is contained in:
元凛
2022-02-10 13:47:52 +08:00
parent 7833b3db99
commit c6a0bf65a1
2 changed files with 2 additions and 4 deletions

View File

@@ -136,7 +136,7 @@ export class IssueCoreEngine implements IIssueCoreEngine {
repo,
issue_number: issueNumber,
});
return issue.data as TIssueInfo;
return issue as unknown as TIssueInfo;
}
public async getUserPermission(username: string) {
@@ -217,7 +217,6 @@ export class IssueCoreEngine implements IIssueCoreEngine {
public async removeLabels(labels: string[]) {
const { owner, repo, octokit, issueNumber, getIssue } = this;
const issue = await getIssue();
console.log(issue)
const baseLabels: string[] = issue.labels.map(({ name }) => name);
const removeLabels = baseLabels.filter(name => labels.includes(name));