diff --git a/src/Infrastructure/BotSharp.Abstraction/Infrastructures/Attributes/BotSharpAuthAttribute.cs b/src/Infrastructure/BotSharp.Abstraction/Infrastructures/Attributes/BotSharpAuthAttribute.cs index 25193cb3..46f28d6c 100644 --- a/src/Infrastructure/BotSharp.Abstraction/Infrastructures/Attributes/BotSharpAuthAttribute.cs +++ b/src/Infrastructure/BotSharp.Abstraction/Infrastructures/Attributes/BotSharpAuthAttribute.cs @@ -26,7 +26,7 @@ public class BotSharpAuthAttribute : Attribute, IAsyncAuthorizationFilter var (isAdmin, user) = await userService.IsAdminUser(userIdentity.Id); if (!isAdmin || user == null) { - context.Result = new BadRequestResult(); + context.Result = new UnauthorizedResult(); } } } diff --git a/src/Plugins/BotSharp.Plugin.OpenAI/BotSharp.Plugin.OpenAI.csproj b/src/Plugins/BotSharp.Plugin.OpenAI/BotSharp.Plugin.OpenAI.csproj index e54033b6..2455e7b5 100644 --- a/src/Plugins/BotSharp.Plugin.OpenAI/BotSharp.Plugin.OpenAI.csproj +++ b/src/Plugins/BotSharp.Plugin.OpenAI/BotSharp.Plugin.OpenAI.csproj @@ -10,10 +10,6 @@ $(SolutionDir)packages - - - -