From f0e9ac50bf39f8058d93e04b7bce07340fbdf36f Mon Sep 17 00:00:00 2001 From: Haiping Chen Date: Thu, 21 Sep 2023 12:12:45 -0500 Subject: [PATCH] Make router agent be the first. --- Directory.Build.props | 2 +- .../BotSharp.OpenAPI/Controllers/AgentController.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index 29b75aca..23dce0b1 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -2,7 +2,7 @@ 10.0 ..\..\..\packages - 0.14.4 + 0.14.5 true \ No newline at end of file diff --git a/src/Infrastructure/BotSharp.OpenAPI/Controllers/AgentController.cs b/src/Infrastructure/BotSharp.OpenAPI/Controllers/AgentController.cs index b75cb239..163b541e 100644 --- a/src/Infrastructure/BotSharp.OpenAPI/Controllers/AgentController.cs +++ b/src/Infrastructure/BotSharp.OpenAPI/Controllers/AgentController.cs @@ -27,7 +27,7 @@ public class AgentController : ControllerBase, IApiAdapter // Add the router as agent var routing = _services.GetRequiredService(); - agents.Add(routing.LoadRouter()); + agents.Insert(0, routing.LoadRouter()); return agents.Select(x => AgentViewModel.FromAgent(x)).ToList(); }