diff --git a/Shoko.Server/Utilities/SeriesSearch.cs b/Shoko.Server/Utilities/SeriesSearch.cs index d1c1e1b1b..491ca9a68 100644 --- a/Shoko.Server/Utilities/SeriesSearch.cs +++ b/Shoko.Server/Utilities/SeriesSearch.cs @@ -85,6 +85,7 @@ public static SearchResult DiceFuzzySearch(string text, string pattern, T return new(); // Always search the longer string for the shorter one. + var match = text; if (pattern.Length > text.Length) (text, pattern) = (pattern, text); @@ -101,7 +102,7 @@ public static SearchResult DiceFuzzySearch(string text, string pattern, T { Distance = result, LengthDifference = Math.Abs(pattern.Length - text.Length), - Match = text, + Match = match, Result = value, }; }