Mercurial > prosody-hg
comparison plugins/mod_invites.lua @ 13725:c51140dfbc4e 13.0
mod_invites: Fix storing --group (thanks lissine)
This made it ignore `--group` completely, but if you incorrectly used
`--group foo` it would store `groups=true`.
Introduced in 9ba11ef91ce4
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Mon, 17 Feb 2025 00:55:27 +0100 |
| parents | 1aa7efabeacb |
| children | 26a0f653793e |
comparison
equal
deleted
inserted
replaced
| 13723:d7bf48d31374 | 13725:c51140dfbc4e |
|---|---|
| 513 end | 513 end |
| 514 allow_reset = username; | 514 allow_reset = username; |
| 515 end | 515 end |
| 516 | 516 |
| 517 local roles = opts.role or {}; | 517 local roles = opts.role or {}; |
| 518 local groups = opts.groups or {}; | 518 local groups = opts.group or {}; |
| 519 | 519 |
| 520 if opts.admin then | 520 if opts.admin then |
| 521 -- Insert it first since we don't get order out of argparse | 521 -- Insert it first since we don't get order out of argparse |
| 522 table.insert(roles, 1, "prosody:admin"); | 522 table.insert(roles, 1, "prosody:admin"); |
| 523 end | 523 end |
