mirror of
https://github.com/oliverbooth/VPLink
synced 2024-11-09 23:45:40 +00:00
Merge branch 'hotfix/ignore_nonrelay' into main
This commit is contained in:
commit
0deb14e137
@ -102,6 +102,9 @@ internal sealed partial class DiscordMessageService : BackgroundService, IDiscor
|
|||||||
if (author.IsBot && !_configurationService.BotConfiguration.RelayBotMessages)
|
if (author.IsBot && !_configurationService.BotConfiguration.RelayBotMessages)
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
|
|
||||||
|
if (message.Channel.Id != _configurationService.DiscordConfiguration.ChannelId)
|
||||||
|
return Task.CompletedTask;
|
||||||
|
|
||||||
string displayName = author.GlobalName ?? author.Username;
|
string displayName = author.GlobalName ?? author.Username;
|
||||||
string unescaped = UnescapeRegex.Replace(message.Content, "$1");
|
string unescaped = UnescapeRegex.Replace(message.Content, "$1");
|
||||||
string content = EscapeRegex.Replace(unescaped, "\\$1");
|
string content = EscapeRegex.Replace(unescaped, "\\$1");
|
||||||
|
Loading…
Reference in New Issue
Block a user