aboutsummaryrefslogtreecommitdiff
path: root/juick-server/src/main/java/com/juick/server/api
diff options
context:
space:
mode:
Diffstat (limited to 'juick-server/src/main/java/com/juick/server/api')
-rw-r--r--juick-server/src/main/java/com/juick/server/api/activity/Profile.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/juick-server/src/main/java/com/juick/server/api/activity/Profile.java b/juick-server/src/main/java/com/juick/server/api/activity/Profile.java
index 6a35f3d9..96ed75d1 100644
--- a/juick-server/src/main/java/com/juick/server/api/activity/Profile.java
+++ b/juick-server/src/main/java/com/juick/server/api/activity/Profile.java
@@ -311,6 +311,15 @@ public class Profile {
}
}
}
+ if (activity instanceof Delete) {
+ Map<String, Object> tombstone = (Map<String, Object>) activity.getObject();
+ if (tombstone.get("type").equals("Tombstone")) {
+ URI actor = URI.create(activity.getActor());
+ URI reply = URI.create((String)tombstone.get("id"));
+ messagesService.deleteReply(actor, reply);
+ return new ResponseEntity<>(HttpStatus.OK);
+ }
+ }
logger.warn("Unknown activity: {}", jsonMapper.writeValueAsString(activity));
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
}