From b2609fdbb744de594bbe1d14cf86f0371fdb7459 Mon Sep 17 00:00:00 2001 From: Jared Goodwin Date: Thu, 27 Jul 2023 14:47:46 -0700 Subject: [PATCH] Add method back for backwards compatibility. --- Server/API/AgentUpdateController.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Server/API/AgentUpdateController.cs b/Server/API/AgentUpdateController.cs index 215c1e46..9bd6900c 100644 --- a/Server/API/AgentUpdateController.cs +++ b/Server/API/AgentUpdateController.cs @@ -37,7 +37,6 @@ public class AgentUpdateController : ControllerBase _logger = logger; } - [HttpGet("[action]/{platform}")] [EnableRateLimiting(PolicyNames.AgentUpdateDownloads)] public async Task DownloadPackage(string platform) @@ -89,6 +88,15 @@ public class AgentUpdateController : ControllerBase } } + + [HttpGet("[action]/{platform}/{downloadId}")] + [EnableRateLimiting(PolicyNames.AgentUpdateDownloads)] + [Obsolete("This method is only for backwards compatibility. Remove after a few releases.")] + public async Task DownloadPackage(string platform, string downloadId) + { + return await DownloadPackage(platform); + } + private async Task CheckForDeviceBan(string deviceIp) { if (string.IsNullOrWhiteSpace(deviceIp))