Software / code / prosody-modules
Comparison
mod_groups_internal/mod_groups_internal.lua @ 6205:8ff8121ff603
mod_groups_internal: Save roster after adding group info (thanks gtech1)
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Thu, 13 Mar 2025 13:00:26 +0000 |
| parent | 6175:e2d130104b98 |
| child | 6211:750d64c47ec6 |
comparison
equal
deleted
inserted
replaced
| 6204:119c0eb65bf3 | 6205:8ff8121ff603 |
|---|---|
| 29 rostermanager.process_inbound_subscription_approval(user, host, contact_jid); | 29 rostermanager.process_inbound_subscription_approval(user, host, contact_jid); |
| 30 | 30 |
| 31 if group_name then | 31 if group_name then |
| 32 local user_roster = rostermanager.load_roster(user, host); | 32 local user_roster = rostermanager.load_roster(user, host); |
| 33 user_roster[contact_jid].groups[group_name] = true; | 33 user_roster[contact_jid].groups[group_name] = true; |
| 34 rostermanager.save_roster(user, host, user_roster, contact_jid); | |
| 34 end | 35 end |
| 35 | 36 |
| 36 -- Push updates to both rosters | 37 -- Push updates to both rosters |
| 37 rostermanager.roster_push(user, host, contact_jid); | 38 rostermanager.roster_push(user, host, contact_jid); |
| 38 rostermanager.roster_push(contact, host, user_jid); | 39 rostermanager.roster_push(contact, host, user_jid); |