Skip to content

Commit

Permalink
Fix bulk loader bug regarding unknown UID predicates. (hypermodeinc#3173
Browse files Browse the repository at this point in the history
)

When a new predicate is created by the bulk loader, it should default to
a list if the object typ is UID.
  • Loading branch information
martinmr authored and dna2github committed Jul 19, 2019
1 parent 5046ccc commit 1db2a7e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dgraph/cmd/bulk/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ func (s *schemaStore) validateType(de *pb.DirectedEdge, objectIsUID bool) {
sch, ok = s.m[de.Attr]
if !ok {
sch = &pb.SchemaUpdate{ValueType: de.ValueType}
if objectIsUID {
sch.List = true
}
s.m[de.Attr] = sch
}
s.Unlock()
Expand Down

0 comments on commit 1db2a7e

Please sign in to comment.