From eb1ebc72dbeb7dcdc17edc236f44a6bdf923f304 Mon Sep 17 00:00:00 2001 From: Toastie Date: Thu, 27 Jun 2024 17:14:55 +1200 Subject: [PATCH] Updated Expressions module --- .../Modules/Expressions/EllieExpressionExtensions.cs | 2 +- src/EllieBot/Modules/Expressions/EllieExpressions.cs | 2 +- .../Modules/Expressions/EllieExpressionsService.cs | 12 ++++++------ src/EllieBot/Modules/Expressions/ExportedExpr.cs | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/EllieBot/Modules/Expressions/EllieExpressionExtensions.cs b/src/EllieBot/Modules/Expressions/EllieExpressionExtensions.cs index 72606a7..0eeb68d 100644 --- a/src/EllieBot/Modules/Expressions/EllieExpressionExtensions.cs +++ b/src/EllieBot/Modules/Expressions/EllieExpressionExtensions.cs @@ -42,7 +42,7 @@ public static class EllieExpressionExtensions () => canMentionEveryone ? ctx.Content[substringIndex..].Trim() : ctx.Content[substringIndex..].Trim().SanitizeMentions(true)); - + var text = SmartText.CreateFrom(cr.Response); text = await repSvc.ReplaceAsync(text, repCtx); diff --git a/src/EllieBot/Modules/Expressions/EllieExpressions.cs b/src/EllieBot/Modules/Expressions/EllieExpressions.cs index 5def4f3..888901d 100644 --- a/src/EllieBot/Modules/Expressions/EllieExpressions.cs +++ b/src/EllieBot/Modules/Expressions/EllieExpressions.cs @@ -1,4 +1,4 @@ -#nullable disable +#nullable disable using EllieBot.Db.Models; namespace EllieBot.Modules.EllieExpressions; diff --git a/src/EllieBot/Modules/Expressions/EllieExpressionsService.cs b/src/EllieBot/Modules/Expressions/EllieExpressionsService.cs index 2f0b740..250c517 100644 --- a/src/EllieBot/Modules/Expressions/EllieExpressionsService.cs +++ b/src/EllieBot/Modules/Expressions/EllieExpressionsService.cs @@ -124,11 +124,11 @@ public sealed class EllieExpressionsService : IExecOnMessage, IReadyExecutor newguildExpressions = guildItems.GroupBy(k => k.GuildId!.Value) .ToDictionary(g => g.Key, g => g.Select(x => - { - x.Trigger = x.Trigger.Replace(MENTION_PH, - _client.CurrentUser.Mention); - return x; - }) + { + x.Trigger = x.Trigger.Replace(MENTION_PH, + _client.CurrentUser.Mention); + return x; + }) .ToArray()) .ToConcurrent(); @@ -259,7 +259,7 @@ public sealed class EllieExpressionsService : IExecOnMessage, IReadyExecutor "ACTUALEXPRESSIONS", expr.Trigger ); - + if (!result.IsAllowed) { var cache = _pc.GetCacheFor(guild.Id); diff --git a/src/EllieBot/Modules/Expressions/ExportedExpr.cs b/src/EllieBot/Modules/Expressions/ExportedExpr.cs index c45fbdc..581c884 100644 --- a/src/EllieBot/Modules/Expressions/ExportedExpr.cs +++ b/src/EllieBot/Modules/Expressions/ExportedExpr.cs @@ -1,4 +1,4 @@ -#nullable disable +#nullable disable using EllieBot.Db.Models; namespace EllieBot.Modules.EllieExpressions;