Software / code / prosody
Comparison
plugins/mod_tombstones.lua @ 12117:0c9b64178eda
mod_tombstones: Add some future TODOs
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Thu, 23 Dec 2021 15:22:47 +0100 |
| parent | 12115:94de6b7596cc |
| child | 12438:a698f65df453 |
comparison
equal
deleted
inserted
replaced
| 12116:efcf25ad5406 | 12117:0c9b64178eda |
|---|---|
| 13 -- Keep tombstones forever by default | 13 -- Keep tombstones forever by default |
| 14 -- | 14 -- |
| 15 -- Rationale: | 15 -- Rationale: |
| 16 -- There is no way to be completely sure when remote services have | 16 -- There is no way to be completely sure when remote services have |
| 17 -- forgotten and revoked all memberships. | 17 -- forgotten and revoked all memberships. |
| 18 | |
| 19 -- TODO If the user left a JID they moved to, return a gone+redirect error | |
| 20 -- TODO Attempt to deregister from MUCs based on bookmarks | |
| 21 -- TODO Unsubscribe from pubsub services if a notification is received | |
| 18 | 22 |
| 19 module:hook_global("user-deleted", function(event) | 23 module:hook_global("user-deleted", function(event) |
| 20 if event.host == module.host then | 24 if event.host == module.host then |
| 21 local ok, err = graveyard:set(nil, event.username, os.time()); | 25 local ok, err = graveyard:set(nil, event.username, os.time()); |
| 22 if not ok then module:log("error", "Could store tombstone for %s: %s", event.username, err); end | 26 if not ok then module:log("error", "Could store tombstone for %s: %s", event.username, err); end |