fix(discord): disambiguate allow-from DM targets (#74303)

* fix(discord): disambiguate allow-from DM targets

* test(discord): align allowFrom precedence

* docs(discord): clarify allowFrom id forms

* fix(discord): align allowFrom precedence

---------

Co-authored-by: 따온이네 맥북프로 <tulisy@ttaon-ine-ui-MacBookPro.local>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
This commit is contained in:
Squirbie
2026-04-29 21:01:28 +09:00
committed by GitHub
parent 4f540c703f
commit 94a85e77de
17 changed files with 353 additions and 14 deletions

View File

@@ -402,7 +402,8 @@ Example:
Multi-account precedence:
- `channels.discord.accounts.default.allowFrom` applies only to the `default` account.
- Named accounts inherit `channels.discord.allowFrom` when their own `allowFrom` is unset.
- For one account, `allowFrom` takes precedence over legacy `dm.allowFrom`.
- Named accounts inherit `channels.discord.allowFrom` when their own `allowFrom` and legacy `dm.allowFrom` are unset.
- Named accounts do not inherit `channels.discord.accounts.default.allowFrom`.
DM target format for delivery:
@@ -410,7 +411,7 @@ Example:
- `user:<id>`
- `<@id>` mention
Bare numeric IDs are ambiguous and rejected unless an explicit user/channel target kind is provided.
Bare numeric IDs normally resolve as channel IDs when a channel default is active, but IDs listed in the account's effective DM `allowFrom` are treated as user DM targets for compatibility.
</Tab>