Skip to content

Commit

Permalink
修改
Browse files Browse the repository at this point in the history
  • Loading branch information
yanjq committed May 23, 2019
1 parent 7697d55 commit 35a41d1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ var (
)

// RecvDefaultHandler 如果没有注册某类消息处理器,那么收到这类消息时,使用这个默认处理器
var RecvDefaultHandler = func(msg *Message) (reply ReplyMsg) {
var RecvDefaultHandler = func(w http.ResponseWriter, r *http.Request, msg *Message) (reply ReplyMsg) {
log.Debugf("unregistered receive message handler %s, use RecvDefaultHandler", msg.MsgType)
return nil
}
Expand Down Expand Up @@ -92,7 +92,7 @@ func HandleMessage(w http.ResponseWriter, r *http.Request, msg *Message) (ret Re
return nil
}

return RecvDefaultHandler(msg)
return RecvDefaultHandler(w, r, msg)
}

// HandleEvent 处理各类事件
Expand Down

0 comments on commit 35a41d1

Please sign in to comment.