a better result
This commit is contained in:
@ -16,19 +16,19 @@ namespace isnd.Controllers
|
||||
{
|
||||
|
||||
// https://docs.microsoft.com/en-us/nuget/api/catalog-resource#versioning
|
||||
[HttpGet("~" + Constants.ApiVersion + ApiConfig.Catalog)]
|
||||
[HttpGet("~" + Constants.ApiVersionPrefix + ApiConfig.Catalog)]
|
||||
public async Task<IActionResult> CatalogIndex()
|
||||
{
|
||||
return Ok(await packageManager.GetCatalogIndexAsync());
|
||||
}
|
||||
|
||||
|
||||
[HttpGet("~" + Constants.ApiVersion + ApiConfig.Registration + "/{id}/{version?}")]
|
||||
[HttpGet("~" + Constants.ApiVersionPrefix + ApiConfig.Registration + "/{id}/{version}.json")]
|
||||
public async Task<IActionResult> CatalogRegistration(string id, string version)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(version))
|
||||
if ("index" == version)
|
||||
{
|
||||
var query = new Data.Catalog.RegistrationPageIndexQuery
|
||||
var query = new Data.Catalog.PackageRegistrationQuery
|
||||
{
|
||||
Query = id,
|
||||
Prerelease = true
|
||||
|
Reference in New Issue
Block a user