Skip to content

Commit ea808ce

Browse files
committed
Fix typo in (*Client).MultiPublish method name
* Rename (*Client).MutliPublish to (*Client).MultiPublish. * Add (*Client).MutliPublish as an alias for backwards compatibility.
1 parent ff4eef9 commit ea808ce

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

nsq.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,13 @@ func (c *Client) Publish(topic string, message []byte) (err error) {
2828
return
2929
}
3030

31-
func (c *Client) MutliPublish(topic string, messages ...[]byte) (err error) {
31+
// MutliPublish is an alias of MultiPublish, here for backwards
32+
// compatibility.
33+
func (c *Client) MutliPublish(topic string, messages ...[]byte) error {
34+
return c.MultiPublish(topic, messages)
35+
}
36+
37+
func (c *Client) MultiPublish(topic string, messages ...[]byte) (err error) {
3238
_, err = c.do("POST", "/mpub", url.Values{
3339
"topic": []string{topic},
3440
}, bytes.Join(messages, []byte("\n")))

0 commit comments

Comments
 (0)