aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFChannel <>2021-08-02 16:33:09 -0700
committerFChannel <>2021-08-02 16:33:09 -0700
commit149f71db2d6e1b704ff2712393da5276a622d4dd (patch)
tree351895a22c58b1e7508f0d2bb27cdb54195d2900
parenteffb65f2d7321d267d444d4231c1aae245e3f619 (diff)
unarchive when remote delete
-rw-r--r--main.go2
-rw-r--r--outboxPost.go3
2 files changed, 3 insertions, 2 deletions
diff --git a/main.go b/main.go
index dd9b9d0..5eed9ef 100644
--- a/main.go
+++ b/main.go
@@ -69,7 +69,7 @@ func main() {
FollowingBoards = GetActorFollowingDB(db, Domain)
- StartupArchive(db)
+ go StartupArchive(db)
go CheckInactive(db)
diff --git a/outboxPost.go b/outboxPost.go
index d54dd8e..0292e4f 100644
--- a/outboxPost.go
+++ b/outboxPost.go
@@ -550,13 +550,14 @@ func ParseInboxRequest(w http.ResponseWriter, r *http.Request, db *sql.DB) {
case "Delete":
for _, e := range activity.To {
actor := GetActorFromDB(db, e)
- if actor.Id != "" {
+ if actor.Id != "" && actor.Id != Domain {
if activity.Object.Replies != nil {
for _, k := range activity.Object.Replies.OrderedItems {
TombstoneObject(db, k.Id)
}
}
TombstoneObject(db, activity.Object.Id)
+ UnArchiveLast(db, actor.Id)
break
}
}