refactor: inline getApiContext()
This commit is contained in:
1 parent
9f9749548a
commit
e7e8e99946
71 files changed
+173
-167
No files matched your search
@@ -20,7 +20,7 @@ export class TranslateEnWordToZn extends BaseAction<Payload, Array<any> | null>
|
||||
PayloadSchema = SchemaData;
|
||||
|
||||
async _handle(payload: Payload) {
|
||||
const NTQQSystemApi = this.CoreContext.getApiContext().SystemApi;
|
||||
const NTQQSystemApi = this.CoreContext.apis.SystemApi;
|
||||
const ret = await NTQQSystemApi.translateEnWordToZn(payload.words);
|
||||
if (ret.result !== 0) {
|
||||
throw new Error('翻译失败');
|
||||
|
||||
Reference in new issue
Block a user