mirror of
https://gitea.com/Lydanne/issues-helper.git
synced 2025-08-21 11:15:50 +08:00
refactor: out core
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import { Octokit } from '@octokit/rest';
|
||||
import * as core from '../core';
|
||||
import { EEmoji } from '../shared';
|
||||
import { TEmoji, TLockReasons, TUpdateMode, TIssueState, TUserPermission } from '../types';
|
||||
import { IIssueBaseInfo, IIssueCoreEngine, IListIssuesParams, TIssueList, TIssueInfo, TCommentList } from './types';
|
||||
@@ -15,8 +14,7 @@ export class IssueCoreEngine implements IIssueCoreEngine {
|
||||
this.owner = _info.owner;
|
||||
this.repo = _info.repo;
|
||||
this.issueNumber = _info.issueNumber;
|
||||
const token = core.getInput('token');
|
||||
this.octokit = new Octokit({ auth: `token ${token}` });
|
||||
this.octokit = new Octokit({ auth: `token ${_info.token}` });
|
||||
} else {
|
||||
console && console.error && console.error(`Init failed, need owner、repo!`);
|
||||
}
|
||||
|
Reference in New Issue
Block a user