diff --git a/VPMReposSynchronizer.Entry/Controllers/VpmRepoController.cs b/VPMReposSynchronizer.Entry/Controllers/VpmRepoController.cs index d5b5b8d..5fb8e1b 100644 --- a/VPMReposSynchronizer.Entry/Controllers/VpmRepoController.cs +++ b/VPMReposSynchronizer.Entry/Controllers/VpmRepoController.cs @@ -3,6 +3,7 @@ using AutoMapper; using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.OutputCaching; +using Microsoft.AspNetCore.WebUtilities; using Microsoft.Extensions.Options; using Semver; using VPMReposSynchronizer.Core.Models.Entity; @@ -134,8 +135,8 @@ private VpmPackage GetPackageWithUrl(VpmPackageEntity package) var vpmPackage = mapper.Map(package); var fileDownloadEndpoint = new Uri(fileHostOptions.Value.BaseUrl, - $"files/{package.FileId}/download/{package.PackageId}.zip").ToString(); - vpmPackage.Url = fileDownloadEndpoint; + $"files/download/{package.PackageId}.zip").ToString(); + vpmPackage.Url = QueryHelpers.AddQueryString(fileDownloadEndpoint, "fileId", package.FileId); return vpmPackage; }