Skip to content

Commit

Permalink
(GH-807) Ensure that Local Only flag is false
Browse files Browse the repository at this point in the history
When searching for packages from a remote source, ensure that the Local
Only flag is always set to false, otherwise, Chocolatey will return a
list of local packages, rather than those from the remote source. This
was discovered when clicking on a remote source while the list of
locally installed packages was still being populated. The search of the
remote source was still using some of the configuration from the query
of the locally installed packages.
  • Loading branch information
gep13 committed Feb 1, 2021
1 parent 5324ac9 commit acbe815
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ public async Task<PackageResults> Search(string query, PackageSearchOptions opti
config.ListCommand.Page = options.CurrentPage;
config.ListCommand.PageSize = options.PageSize;
config.Prerelease = options.IncludePrerelease;
config.ListCommand.LocalOnly = false;
if (string.IsNullOrWhiteSpace(query) || !string.IsNullOrWhiteSpace(options.SortColumn))
{
config.ListCommand.OrderByPopularity = string.IsNullOrWhiteSpace(options.SortColumn)
Expand Down

0 comments on commit acbe815

Please sign in to comment.