mirror of
https://gitea.com/Lydanne/issues-helper.git
synced 2025-08-19 10:15:59 +08:00
fix: getIssue
This commit is contained in:
3
dist/index.js
vendored
3
dist/index.js
vendored
@@ -15673,7 +15673,7 @@ class IssueCoreEngine {
|
||||
repo,
|
||||
issue_number: issueNumber,
|
||||
});
|
||||
return issue.data;
|
||||
return issue;
|
||||
});
|
||||
}
|
||||
getUserPermission(username) {
|
||||
@@ -15756,7 +15756,6 @@ class IssueCoreEngine {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const { owner, repo, octokit, issueNumber, getIssue } = this;
|
||||
const issue = yield getIssue();
|
||||
console.log(issue);
|
||||
const baseLabels = issue.labels.map(({ name }) => name);
|
||||
const removeLabels = baseLabels.filter(name => labels.includes(name));
|
||||
for (const label of removeLabels) {
|
||||
|
@@ -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));
|
||||
|
Reference in New Issue
Block a user