diff --git a/src/chocolatey/infrastructure.app/nuget/NugetList.cs b/src/chocolatey/infrastructure.app/nuget/NugetList.cs index 538aa2620f..71d5a86ef9 100644 --- a/src/chocolatey/infrastructure.app/nuget/NugetList.cs +++ b/src/chocolatey/infrastructure.app/nuget/NugetList.cs @@ -60,7 +60,6 @@ private static IQueryable execute_package_search(ChocolateyConfigurati IQueryable results = packageRepository.Search(searchTermLower, configuration.Prerelease); - if (configuration.ListCommand.Page.HasValue) { results = results.Skip(configuration.ListCommand.PageSize * configuration.ListCommand.Page.Value).Take(configuration.ListCommand.PageSize); @@ -68,7 +67,7 @@ private static IQueryable execute_package_search(ChocolateyConfigurati if (configuration.ListCommand.Exact) { - results = results.Where(p => p.Id.ToLower() == searchTermLower); + results = packageRepository.FindPackagesById(searchTermLower).AsQueryable(); } if (configuration.ListCommand.ByIdOnly)