File tree Expand file tree Collapse file tree 1 file changed +20
-11
lines changed Expand file tree Collapse file tree 1 file changed +20
-11
lines changed Original file line number Diff line number Diff line change @@ -741,7 +741,7 @@ func ExampleTxn_Mutate_facets() {
741741 }
742742
743743 type Root struct {
744- Me []Person `json:"me"`
744+ Me []json. RawMessage `json:"me"`
745745 }
746746
747747 var r Root
@@ -754,33 +754,42 @@ func ExampleTxn_Mutate_facets() {
754754 fmt .Printf ("%s\n " , out )
755755 // Output: [
756756 // {
757- // "name": "Alice",
758757 // "name|origin": "Indonesia",
758+ // "name": "Alice",
759+ // "dgraph.type": [
760+ // "Person"
761+ // ],
759762 // "friends": [
760763 // {
761764 // "name": "Bob",
762- // "friends|since": "2009-11-10T23:00:00Z",
763- // "friends|family": "yes",
764- // "friends|age": 13,
765- // "friends|close": true,
766765 // "dgraph.type": [
767766 // "Person"
768767 // ]
769768 // }
770769 // ],
771- // "friends|since": "0001-01-01T00:00:00Z",
770+ // "friends|age": {
771+ // "0": 13
772+ // },
773+ // "friends|close": {
774+ // "0": true
775+ // },
776+ // "friends|family": {
777+ // "0": "yes"
778+ // },
779+ // "friends|since": {
780+ // "0": "2009-11-10T23:00:00Z"
781+ // },
772782 // "school": [
773783 // {
774784 // "name": "Wellington School",
775- // "school|since": "2009-11-10T23:00:00Z",
776785 // "dgraph.type": [
777786 // "Institution"
778787 // ]
779788 // }
780789 // ],
781- // "dgraph.type ": [
782- // "Person "
783- // ]
790+ // "school|since ": {
791+ // "0": "2009-11-10T23:00:00Z "
792+ // }
784793 // }
785794 // ]
786795}
You can’t perform that action at this time.
0 commit comments