From bfd79e1af2300d018e51e384cdbffd9daab1e364 Mon Sep 17 00:00:00 2001 From: Alekhya Date: Fri, 26 Jun 2020 10:20:54 -0700 Subject: [PATCH] reduced the description weight by half (#4519) --- .../launcher/Plugins/Microsoft.Plugin.Program/Programs/UWP.cs | 2 +- .../launcher/Plugins/Microsoft.Plugin.Program/Programs/Win32.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/UWP.cs b/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/UWP.cs index 4849aefeb2..92411d91ea 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/UWP.cs +++ b/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/UWP.cs @@ -265,7 +265,7 @@ namespace Microsoft.Plugin.Program.Programs { var displayNameMatch = StringMatcher.FuzzySearch(query, DisplayName); var descriptionMatch = StringMatcher.FuzzySearch(query, Description); - var score = new[] { displayNameMatch.Score, descriptionMatch.Score }.Max(); + var score = new[] { displayNameMatch.Score, descriptionMatch.Score/2 }.Max(); return score; } diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/Win32.cs b/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/Win32.cs index d7c0c12e99..abecdf7880 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/Win32.cs +++ b/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/Win32.cs @@ -57,7 +57,7 @@ namespace Microsoft.Plugin.Program.Programs var nameMatch = StringMatcher.FuzzySearch(query, Name); var descriptionMatch = StringMatcher.FuzzySearch(query, Description); var executableNameMatch = StringMatcher.FuzzySearch(query, ExecutableName); - var score = new[] { nameMatch.Score, descriptionMatch.Score, executableNameMatch.Score }.Max(); + var score = new[] { nameMatch.Score, descriptionMatch.Score/2, executableNameMatch.Score }.Max(); return score; }