schema/edge: fix edge annotations with to/from builders (#679)

This commit is contained in:
Ariel Mashraki
2020-08-20 12:15:43 +03:00
committed by GitHub
parent b18716931d
commit 5e56543133
4 changed files with 46 additions and 2 deletions

View File

@@ -190,7 +190,7 @@ func (g *Graph) addEdges(schema *load.Schema) {
Unique: ref.Unique,
Optional: !ref.Required,
StructTag: ref.Tag,
Annotations: e.Annotations,
Annotations: ref.Annotations,
})
default:
panic(graphError{"edge must be either an assoc or inverse edge"})