From d521390733761fe1db13de575c253afd5c743085 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ola=20Holmstr=C3=B6m?= Date: Thu, 18 May 2017 12:55:55 +0200 Subject: [PATCH] Fix HandleSentMessageBinary, close #32. --- CHANGELOG.md | 4 ++++ README.md | 1 + melody.go | 2 +- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 613c965..ff511dd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 2017-05-18 + +* Fix `HandleSentMessageBinary`. + ## 2017-04-11 * Allow any origin by default. diff --git a/README.md b/README.md index cdddf7e..67e3ab5 100644 --- a/README.md +++ b/README.md @@ -173,6 +173,7 @@ func main() { * Matt Caldwell (@mattcaldwell) * Heikki Uljas (@huljas) * Robbie Trencheny (@robbiet480) +* yangjinecho (@yangjinecho) ## FAQ diff --git a/melody.go b/melody.go index 39cbd97..6e416b1 100644 --- a/melody.go +++ b/melody.go @@ -129,7 +129,7 @@ func (m *Melody) HandleSentMessage(fn func(*Session, []byte)) { // HandleSentMessageBinary fires fn when a binary message is successfully sent. func (m *Melody) HandleSentMessageBinary(fn func(*Session, []byte)) { - m.messageSentHandler = fn + m.messageSentHandlerBinary = fn } // HandleError fires fn when a session has an error.