Changes
2 changed files (+8/-0)
-
-
@@ -541,6 +541,8 @@ func (o *Object) UnmarshalJSON(data []byte) error {o.InReplyTo = getAPItem(data, "inReplyTo") o.Published = getAPTime(data, "published") o.StartTime = getAPTime(data, "startTime") o.Icon = getAPItem(data, "icon") o.Image = getAPItem(data, "image") o.Updated = getAPTime(data, "updated") to := getAPItems(data, "to") if to != nil {
-
-
-
@@ -330,6 +330,12 @@ func validateEmptyObject(o Object, t *testing.T) {if o.URL != nil { t.Errorf("Unmarshalled object %T should have empty URL, received %v", o, o.URL) } if o.Icon != nil { t.Errorf("Unmarshalled object %T should have empty Icon, received %v", o, o.Icon) } if o.Image != nil { t.Errorf("Unmarshalled object %T should have empty Image, received %v", o, o.Image) } if !o.Published.IsZero() { t.Errorf("Unmarshalled object %T should have empty Published, received %q", o, o.Published) }
-