Skip to content

Commit

Permalink
pre-allocate error message
Browse files Browse the repository at this point in the history
  • Loading branch information
quipo committed Mar 21, 2016
1 parent 53ef5db commit c197c2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion client.go
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ func (c *StatsdClient) SendEvent(e event.Event) error {
// Tries to bundle many together into one fmt.Fprintf based on UDPPayloadSize.
func (c *StatsdClient) SendEvents(events map[string]event.Event) error {
if c.conn == nil {
return fmt.Errorf("cannot send stats, not connected to StatsD server")
return errNotConnected
}

var n int
Expand Down

0 comments on commit c197c2a

Please sign in to comment.