refactor: inline getApiContext()

This commit is contained in:
Wesley F. Young
2024-08-11 19:10:42 +08:00
parent e88c0346f3
commit 89e777f99e
71 changed files with 173 additions and 167 deletions

View File

@@ -19,7 +19,7 @@ export class SetMsgEmojiLike extends BaseAction<Payload, any> {
PayloadSchema = SchemaData;
async _handle(payload: Payload) {
const NTQQMsgApi = this.CoreContext.getApiContext().MsgApi;
const NTQQMsgApi = this.CoreContext.apis.MsgApi;
const msg = MessageUnique.getMsgIdAndPeerByShortId(parseInt(payload.message_id.toString()));
if (!msg) {
throw new Error('msg not found');