Skip to content

Commit

Permalink
fix: this 错误
Browse files Browse the repository at this point in the history
  • Loading branch information
lc-cn committed Apr 29, 2024
1 parent cb4da6e commit ed1816e
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/adapters/icqq/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ export default class IcqqAdapter extends Adapter<"icqq", Sendable> {
},
user_id: data.user_id || data.sender?.user_id || data.sender?.tiny_id,
};
delete result['group']
delete result['member']
delete result['discuss']
delete result['friend']
delete result["group"];
delete result["member"];
delete result["discuss"];
delete result["friend"];
if (data.source) {
const message_id =
data.message_type === "group"
Expand Down Expand Up @@ -203,7 +203,7 @@ export default class IcqqAdapter extends Adapter<"icqq", Sendable> {
): Promise<OneBot.Message<V>> {
const oneBot = this.getOneBot<Client>(uin);
if (!oneBot) throw new Error("No one");
let { message, ...result } = await oneBot.internal.getMsg.call(oneBot.internal,message_id);
let { message, ...result } = await oneBot.internal.getMsg.call(oneBot.internal, message_id);
const segments = this.toSegment(version, message);
return {
...result,
Expand All @@ -219,8 +219,8 @@ export default class IcqqAdapter extends Adapter<"icqq", Sendable> {
): Promise<any> {
try {
if (this[method]) return this[method](uin, version, args);
const client=this.oneBots.get(uin)?.internal
return client[method].call(this,...args);
const client = this.oneBots.get(uin)?.internal;
return client[method].call(client, ...args);
} catch {
throw OneBot.UnsupportedMethodError;
}
Expand Down

0 comments on commit ed1816e

Please sign in to comment.