mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2026-02-12 07:50:25 +00:00
refactor: inline all NTQQXxxApi uses
This commit is contained in:
@@ -14,7 +14,6 @@ export class OneBotFriendApi {
|
||||
|
||||
//使用前预先判断 busiId 1061
|
||||
async parsePrivatePokeEvent(grayTipElement: GrayTipElement) {
|
||||
const NTQQUserApi = this.core.apis.UserApi;
|
||||
const json = JSON.parse(grayTipElement.jsonGrayTipElement.jsonStr);
|
||||
let pokedetail: any[] = json.items;
|
||||
//筛选item带有uid的元素
|
||||
@@ -23,8 +22,8 @@ export class OneBotFriendApi {
|
||||
if (pokedetail.length == 2) {
|
||||
return new OB11FriendPokeEvent(
|
||||
this.core,
|
||||
parseInt((await NTQQUserApi.getUinByUidV2(pokedetail[0].uid))!),
|
||||
parseInt((await NTQQUserApi.getUinByUidV2(pokedetail[1].uid))!),
|
||||
parseInt((await this.core.apis.UserApi.getUinByUidV2(pokedetail[0].uid))!),
|
||||
parseInt((await this.core.apis.UserApi.getUinByUidV2(pokedetail[1].uid))!),
|
||||
pokedetail,
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user