lib/redgraph/edge.rb in redgraph-0.1.2 vs lib/redgraph/edge.rb in redgraph-0.1.3

- old
+ new

@@ -1,13 +1,15 @@ # frozen_string_literal: true module Redgraph class Edge - attr_accessor :id, :src, :dest, :type, :properties + attr_accessor :id, :src, :dest, :src_id, :dest_id, :type, :properties def initialize(src: nil, dest: nil, type: nil, properties: {}) @src = src + @src_id = @src.id if @src @dest = dest + @dest_id = @dest.id if @dest @type = type @properties = properties end def persisted?