Skip to content

Commit d2b2794

Browse files
alexanderfastloic-sharma
authored andcommitted
Fix AmbiguousMatchException when deleting package (#177)
Fixes #176
1 parent c38a4bd commit d2b2794

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/BaGet/Controllers/PackagePublishController.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
using System;
1+
using System;
22
using System.Threading;
33
using System.Threading.Tasks;
44
using BaGet.Core.Services;
55
using BaGet.Extensions;
6-
using Microsoft.AspNetCore.Http;
76
using Microsoft.AspNetCore.Mvc;
87
using Microsoft.Extensions.Logging;
98
using NuGet.Versioning;
@@ -77,6 +76,7 @@ public async Task Upload(CancellationToken cancellationToken)
7776
}
7877
}
7978

79+
[HttpDelete]
8080
public async Task<IActionResult> Delete(string id, string version, CancellationToken cancellationToken)
8181
{
8282
if (!NuGetVersion.TryParse(version, out var nugetVersion))
@@ -99,6 +99,7 @@ public async Task<IActionResult> Delete(string id, string version, CancellationT
9999
}
100100
}
101101

102+
[HttpPost]
102103
public async Task<IActionResult> Relist(string id, string version)
103104
{
104105
if (!NuGetVersion.TryParse(version, out var nugetVersion))

0 commit comments

Comments
 (0)