Skip to content

Commit

Permalink
fix: 修复关于INotifyEvent的一些问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Redmomn committed Jul 15, 2024
1 parent 2717203 commit e3a1cc4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions client/base.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ type QQClient struct {
NewFriendRequestEvent EventHandle[*event.NewFriendRequest] // 好友申请
FriendRecallEvent EventHandle[*event.FriendRecall]
RenameEvent EventHandle[*event.Rename]
FriendNotifyEvent EventHandle[*event.INotifyEvent]
GroupNotifyEvent EventHandle[*event.INotifyEvent]
FriendNotifyEvent EventHandle[event.INotifyEvent]
GroupNotifyEvent EventHandle[event.INotifyEvent]

// client event handles
eventHandlers eventHandlers
Expand Down
4 changes: 2 additions & 2 deletions client/listener.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ func decodeOlPushServicePacket(c *QQClient, pkt *network.Packet) (any, error) {
if err != nil {
return nil, err
}
c.FriendPokeEvent.dispatch(c, eventConverter.ParsePokeEvent(&pb))
c.FriendNotifyEvent.dispatch(c, eventConverter.ParsePokeEvent(&pb))
default:
c.warning("unknown subtype %d of type 0x210, proto data: %x", subType, pkg.Body.MsgContent)
}
Expand Down Expand Up @@ -199,7 +199,7 @@ func decodeOlPushServicePacket(c *QQClient, pkt *network.Packet) (any, error) {
groupUin = uint32(r.Vaule.(int64))
}
}
c.GroupPokeEvent.dispatch(c, eventConverter.PaeseGroupPokeEvent(&pb, groupUin))
c.GroupNotifyEvent.dispatch(c, eventConverter.PaeseGroupPokeEvent(&pb, groupUin))
return nil, nil
case 17: // recall
reader := binary.NewReader(pkg.Body.MsgContent)
Expand Down

0 comments on commit e3a1cc4

Please sign in to comment.