handle announce of update like announce of create
This commit is contained in:
parent
92b1c61dc1
commit
a7adc79f20
|
@ -631,13 +631,17 @@ func xonksaver(user *WhatAbout, item junk.Junk, origin string) *Honk {
|
||||||
case "Announce":
|
case "Announce":
|
||||||
obj, ok = item.GetMap("object")
|
obj, ok = item.GetMap("object")
|
||||||
if ok {
|
if ok {
|
||||||
|
// at some point we should just recurse
|
||||||
what, ok := obj.GetString("type")
|
what, ok := obj.GetString("type")
|
||||||
if ok && what == "Create" {
|
if ok && (what == "Create" || what == "Update") {
|
||||||
obj, ok = obj.GetMap("object")
|
obj, ok = obj.GetMap("object")
|
||||||
if !ok {
|
if !ok {
|
||||||
ilog.Printf("lost object inside create %s", id)
|
ilog.Printf("lost object inside announce %s", id)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
if what == "Update" {
|
||||||
|
isUpdate = true
|
||||||
|
}
|
||||||
what, _ = obj.GetString("type")
|
what, _ = obj.GetString("type")
|
||||||
}
|
}
|
||||||
if what == "Page" {
|
if what == "Page" {
|
||||||
|
|
Loading…
Reference in New Issue