Skip to content

Commit 7add907

Browse files
committed
fixing issue
1 parent d286517 commit 7add907

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

kbanalysis/src/index.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,12 @@ try{
3535
for(let issue of issues){
3636
const t = await handleKBIssue(client, owner, repo, issue);
3737
}
38+
core.info(`[!] Moved ${issues.length} issues`)
39+
exit(0);
40+
}else{
41+
core.info("No KB issues found");
3842
}
3943

40-
4144
core.info(`[X] Unable to list KB issues`)
4245
exit(0);
4346
}

kbanalysis/src/issues-util.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,8 @@ export async function handleKBIssue(
1212
const storage_issue = 1380;
1313
const comment_id = 1308209074;
1414
let comment = await prepareComment(octokit, owner, repo, issue);
15-
core.info(`Analysis For ${issue.title}:\n ${comment}`);
15+
core.info(`[!] Moving ${issue.title}`);
1616

17-
return "test_return"
1817
let resp = await octokit.rest.issues.getComment({
1918
owner: owner,
2019
repo: repo,
@@ -43,13 +42,12 @@ export async function handleKBIssue(
4342
});
4443
if (resp3.status === 200) {
4544
core.info(`[!] Closed Issue ${issue.number}`);
46-
return "success"
45+
return "success";
4746
} else {
4847
core.info(`[X] Unable to close issue ${issue.number}`);
49-
return "error while closing issue"
48+
return "error: unable to close issue";
5049
}
5150
}
52-
5351
}
5452
core.info(`[X] Unable to handle: ${issue.title} `);
5553
return "error: unable to get comment";

0 commit comments

Comments
 (0)