Skip to content

Commit

Permalink
Update Client documentation
Browse files Browse the repository at this point in the history
* Added additional variable to fulfil NewUDPClient function requirement (there was one instead of 2) and it caused multiple-value client.NewUDPClient() in single-value context error

* Update README.md

Added error handling.
  • Loading branch information
dsalbert authored and e-dard committed Dec 1, 2016
1 parent 7106c8a commit e0291e4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions client/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,11 @@ The **InfluxDB** client also supports writing over UDP.
```go
func WriteUDP() {
// Make client
c := client.NewUDPClient("localhost:8089")

c, err := client.NewUDPClient("localhost:8089")
if err != nil {
panic(err.Error())
}

// Create a new point batch
bp, _ := client.NewBatchPoints(client.BatchPointsConfig{
Precision: "s",
Expand Down

0 comments on commit e0291e4

Please sign in to comment.