diff --git a/hugegraph-api/src/main/java/com/baidu/hugegraph/api/graph/EdgeAPI.java b/hugegraph-api/src/main/java/com/baidu/hugegraph/api/graph/EdgeAPI.java index e2913a7247..caa6a21341 100644 --- a/hugegraph-api/src/main/java/com/baidu/hugegraph/api/graph/EdgeAPI.java +++ b/hugegraph-api/src/main/java/com/baidu/hugegraph/api/graph/EdgeAPI.java @@ -464,7 +464,7 @@ private Id getEdgeId(HugeGraph g, JsonEdge newEdge) { Directions.OUT, labelId, sortKeys, HugeVertex.getIdValue(newEdge.target)); if (newEdge.id != null) { - E.checkArgument(edgeId.equals(newEdge.id), + E.checkArgument(edgeId.asString().equals(newEdge.id), "The ids are different between server and " + "request body ('%s' != '%s'). And note the sort " + "key values should either be null or equal to " +