diff --git a/gremlin-go/example/example.go b/gremlin-go/example/example.go index 4ce2c3c585e..02f91f7e8a3 100644 --- a/gremlin-go/example/example.go +++ b/gremlin-go/example/example.go @@ -87,6 +87,10 @@ func basicGremlinExample() { // Iterate() does not return any data and is used to just generate side-effects (i.e. write data to the database) promise := g.V(v1Vertex).AddE("knows").To(v2Vertex).Property("weight", 0.75).Iterate() err = <-promise + if err != nil { + fmt.Println(err) + return + } promise = g.V(v1Vertex).AddE("knows").To(v3Vertex).Property("weight", 0.75).Iterate() err = <-promise if err != nil {