mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2026-02-13 00:10:27 +00:00
refactor: rename all coreContext -> core
This commit is contained in:
@@ -17,10 +17,10 @@ type Payload = FromSchema<typeof SchemaData>;
|
||||
|
||||
export class TranslateEnWordToZn extends BaseAction<Payload, Array<any> | null> {
|
||||
actionName = ActionName.TranslateEnWordToZn;
|
||||
PayloadSchema = SchemaData;
|
||||
payloadSchema = SchemaData;
|
||||
|
||||
async _handle(payload: Payload) {
|
||||
const NTQQSystemApi = this.CoreContext.apis.SystemApi;
|
||||
const NTQQSystemApi = this.core.apis.SystemApi;
|
||||
const ret = await NTQQSystemApi.translateEnWordToZn(payload.words);
|
||||
if (ret.result !== 0) {
|
||||
throw new Error('翻译失败');
|
||||
|
||||
Reference in New Issue
Block a user